teleren/devto huggingface dataset:
How to start a developer career in 2020?
Tags: beginners, devops, hiring
Published: 2019-11-25 20:50:16

Last friday I organized the first german east coast DevOps meetup. That was really cool to get in touch with this guys because Greifswald is a real outlying town in the very north-east of germany.

Because I do development since so many years it was hard to prepare for my lecture on this topic and I found out that it will be hard as a newbie to get some orientation.

Here is what I thought is a good starting point:
1. Do the Angular Tour of Heroes or the REACT TicTacToe and get in touch with the concepts and fundamental Javascript/HTML/CSS stuff and try doing it in Typescript
    https://www.w3schools.com/html/
    https://angular.io/tutorial/toh-pt0
    https://reactjs.org/tutorial/tutorial.html
    https://www.typescriptlang.org/docs/home.html

2. Discover REST API development
    https://scotch.io/tutorials/speed-up-your-restful-api-development-in-node-js-with-swagger
    https://docs.microsoft.com/de-de/azure/architecture/best-practices/api-design

3. Learn about databases and persistance
    http://www.postgresqltutorial.com/
    https://flywaydb.org/
4. Learn Docker
    https://docs.docker.com/engine/docker-overview/
5. Use Docker
<pre>
    docker run --rm --name pg-docker -e POSTGRES_DB=farm-history-db -d -p 5432:5432 -v $DATA:/var/lib/postgresql/data  postgres
</pre>
6. Learn about JWT
    https://jasonwatmore.com/post/2019/06/22/angular-8-jwt-authentication-example-tutorial
7. Learn E2E Testing
    https://www.protractortest.org/#/tutorial
https://docs.cypress.io/guides/overview/why-cypress.html#In-a-nutshell
8. Deploy stuff to the cloud using Terraform
    https://www.terraform.io/intro/index.html

There are so many other things like patterns, unit testing, git, npm, Scala, .NET core, other DB types, ... the list seems endless but the topics mentioned here you need to become familiar to decide on other technologies.

This is it, basic stuff is on the way and you are not lost in translation any more.

Regards,
Michael
Como registrar as rotas de seus pacotes de forma CORRETA!
Tags: laravel, php, webdev, ptbr
Published: 2019-11-25 20:36:44

Primeiro você deve criar um `SericeProvider` no seu pacote para que no Laravel possa reconhecer as rotas que foram definidas.

Como estamos falando de um **pacote** então não temos o `tinker`para nos ajudar com o seu recurso de criação de ServiceProvider `artisan make:provider`, sendo assim precisamos criar ele na mão.

Crie um arquivo chamado `RouteServeProvider` dentro da sua estrutura do seu pacote

```sh
$ touch vendor/namespace/Providers/RouteServiceProvider.php
```

Agora vamos escrever o código do nosso Provider.

```php
<?php

namespace vendor\namespace\Providers;

use Illuminate\Routing\Router;

#Classe que possui todas as configurações corretas para a injeção de rotas
use Illuminate\Foundation\Support\Providers\RouteServiceProvider as ServiceProvider;

class RouteServiceProvider extends ServiceProvider
{
    /**
     * Bootstrap the application services.
     *
     * @return void
     */
    public function boot(Router $router)
    {
        parent::boot($router);
    }

    public function map(Router $router)
    {
        $router->group([
            #Namespace dos controllers do seu pacote
            'namespace' => 'vendor\namespace\Http\Controllers',
            'prefix' => 'myprefix',
            'middleware' => ['...'],
        ], function ($router) {
            require app_path('path/to/my/routes.php');
        });
    }
}

```

Caso seu pacote seja compatível com o Laravel <= 5.4 você deve instruir ao usuário do seu pacote a registrar ele nos providers do projeto.

Para que o provider seja descoberto automaticamente adicione ele nos extras do seu `composer.json`

```json
"extra": {
    "laravel": {
        "providers": [
            "vendor\\namespace\\Providers\\RouteServiceProvider"
        ],
    }
}
```

E pronto! a partir de agora você pode escrever as rotas do seu pacote normalmente, assim como as rotas do seu projeto!



Estrutura final do nosso pacote

```sh
vendor/
    namespace/
        Http/
            Controllers/
        Providers/
            RouteServiceProvider.php
        path/
            to/
                my/
                    routes.php
```

Então é isso galera! até a próxima! :D
SOLVED: What does type A5_C, PA5_C, and Pc mean?
Tags: cpp, beginners
Published: 2019-11-25 20:23:33

UPDATE (Nov 26):
Through more indepth analysis! Finally figured out what it means! At least I hope it's really what it means, but seeing how it trends with other types, I think it's correct! 

A5_c - means it's an array of 5 char type elements
PA5_c - means it's a pointer to the array of 5 char type elements
Pc - means pointer that holds an address to another variable

Praise God! 

Hello everyone! 
I recently started to learn cpp on my own and is learning the concept of pointers, which I hear is a very challenging concept, so I wanted to practice until I fully understand it. The part I am on is about arrays and pointers and through using the mac terminal and the GNU compiler, I wrote a simple program like this and also the results can be found in the comments, could someone help me understand what A5_C, PA5_C, and Pc mean? And also please correct me if anything i thought i understood is incorrect :). Thank you in advance!

````cpp
#include <iostream>
#include <string.h>
#include <typeinfo>

int main() {

char name[] = "Lily";

//prints size of char array which is 5 bytes in this case
std::cout << sizeof(name) << std::endl;

//------------------------------------------------------
//this prints Lily which is of type: A5_C (huh?????????)
std::cout << name << " which is of type: " << typeid(name).name() << std::endl;

//------------------------------------------------------
//this prints 0x7ffee6425b07 which is of type PA5_C 
//(is PA5_C meaning address?)

std::cout << &name << " which is of type: " << typeid(&name).name() << std::endl;

//------------------------------------------------------
//this prints L which is of type c
//which I understand because it's dereferencing the pointer 
//and getting me the content that's occupying the address

std::cout << *name << " which is of type: " << typeid(*name).name() << std::endl;

//------------------------------------------------------
//this prints ily which is of type Pc
//I am assuming this means pointer type but
//then why is it significantly more different than type of name?

std::cout << (name+1) << " which is of type " << typeid(name+1).name() << std::endl;

//------------------------------------------------------
//this prints i which is of type c
//which makes sense, because you can do
//arithmetics with pointer variables and this adds 
//1 byte to name so it gives me 
//the value in the address 1 unit above

std::cout << *(name+1) << " which is of type " << typeid(*(name+1)).name() << std::endl;

//------------------------------------------------------
//this prints _blank which is of type c 
//and makes sense but it's very bad because 
//c++ have no bounds checking for arrays and 
//so this address might store some garbage value

std::cout << *(name+5) << " which is of type " << typeid(*(name+5)).name() << std::endl;

return 0;

}

```
Please excuse the messy commenting, but hopefully it's clear!!
Set Up Firebase Database in Ionic 4 and Angular 8
Tags: firebase, setupfirebasedatabase, ionic4, angular8
Published: 2020-02-07 09:36:46

---
title: Set Up Firebase Database in Ionic 4 and Angular 8
published: true
date: 2019-11-25 19:47:11 UTC
tags: Firebase ,Set Up Firebase Database,Ionic 4, Angular 8
canonical_url: https://www.positronx.io/set-up-firebase-database-in-ionic-angular/
---

The post [Set Up Firebase Database in Ionic 4 and Angular 8](https://www.positronx.io/set-up-firebase-database-in-ionic-angular/) appeared first on [positronX.io](https://www.positronx.io).

**In this Ionic 4 Firebase tutorial, we are going to look at step by step how to set up Firebase Realtime Database in Ionic 4/Angular 8 project.**

Firebase is a popularly known Google product and Its a NoSQL Realtime Database. Working with Firebase is easy, It doesn’t make its user to lost in its dashboard due to its superb User Experience. Firebase offers top-notch features for building web and mobile applications swiftly:

[click here to read more](https://www.positronx.io/set-up-firebase-database-in-ionic-angular/)
Autocomplete Dropdown using native HTML
Tags: webdev, html, showdev, javascript
Published: 2019-11-25 19:22:32

---
title: Autocomplete Dropdown using native HTML
published: true
description: You have probably seen dropdowns with autocomplete ability in jQuery, React, Vue, etc. Most of us would assume it is only possible with the help of Javascript. But is it possible without Javascript? Yes, it is! I came across an HTML element that is supported by browsers and does the same.
tags: webdev, html, showdev, javascript
series: Tips & Tricks
---

You have probably seen dropdowns with autocomplete ability in jQuery, React, Vue, etc. Most of us would assume it is only possible with the help of Javascript. But is it possible without Javascript? Yes, it is! I came across an HTML element that is supported by browsers and does the same.

The secret element is the `datalist` element. If we attach a `datalist` to an already existing `input` element we get a native dropdown with autocomplete! Booom, and it just works 🚀 

Plus it is supported by [all modern browsers](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/datalist).

```html
<input list="europe-countries" placeholder="Start typing...">
<datalist id="europe-countries">
  <option>Russia</option>
  <option>Germany</option>
  <option>United Kingdom</option>
  ...
</datalist>
```

The input starts behaving like a select and when we start typing it searches inside the options of the datalist.

Let's see it in action!

{% codepen https://codepen.io/twhite96/pen/mddYYVQ default-tab=html,result %}

Incredible 🦄
Charming the Python: Strings
Tags: python, beginners
Published: 2019-11-25 19:16:32


*If coding tutorials with math examples are the bane of your existence, keep reading. This series uses relatable examples like dogs and cats.*

---
## Strings

###  Creating a string
Strings are a bunch of characters within quotes.
```python
'7his is a string'

"Th15 is also a string!"

"""This is a 
multi-line 
string."""

'This is a "quote" inside of a string.'

"This is also 'quote' inside of a string"
```
### String Concatenation
Concatenation is a long word that means you're putting things together.

```python
first_name = "Vicki"
last_name = 'Langer'

full_name = first_name + " " + last_name

print(full_name)
>>>Vicki Langer
```
### Escape Sequences in string

| Sequence | What it does |
|--|--|
| \n | new line |
| \t | tab or 8 spaces |
| \\ | backslash |
| \' | single quote |
| \" | double quote |

```python
print('Are you enjoying my python notes.\nLet me know in the comments')
>>>Are you enjoying my python notes.
>>>Let me know in the comments
```
###  String formating
string formating is a great way to template things
```python
name = 'Vicki'
language = 'Python'
formatted_string = "Hi, I'm {}. I am writing about {}".format(name, language)
print(formatted_string)
>>>Hi, I'm Vicki. I am writing about Python
```

```python
# this is called "f-string"
name = 'Vicki'
language = 'Python'
formatted_string = f"Hi, I'm {name}. I am writing about {language}"
```

### Accessing characters in strings by index

the first character in the string is considered `0`
You may also get the last charater by referring to `-1`


| p | y | t | h | o | n
|--|--|--|--|--|--|
| 0 | 1 | 2 | 3 | 4 | 5 |
| -6 | -5 | -4 | -3 | -2 | -1 |

```python
language = 'python'

first_letter = language[0]
print(first_letter)
>>> p

last_letter = language[-1]
print(last_letter)
>>> n
```

### Slicing Python Strings
```python

first_three = language[0,3] # starts at zero index and up to but not including index 3
>>>pyt
>
last_three = language[3:6]
>>>hon
```
### Reversing a string
```python
greeting = 'Hello, World!'
print(greeting[::-1]) 
>>>!dlroW ,olleH
```
### Skipping characters while slicing
```python
language = 'the next line is telling us we want to look at the characters between 0 index and 100 index, then it is only going to give us ever 2nd number'
every_other = language[0,100:2]
```

---
Series based on {% post https://dev.to/asabeneh/30daysofpyton-challenge-43ii %}
🎤  Launching - Tech Podcast 🎤 🎧 📹 for the World! Made with ❤️ in Berlin, Germany 🇩🇪 (with promo video)
Tags: podcast, javascript, react, typescript
Published: 2019-11-25 19:07:56

Hello world and Hello Everyone :wave:

<h4>Wow, I am super excited to announce this 😱 </h4>

Winter is coming with Darkness and sadness 😰

And in this Winter, I am planning to start a Podcast 🎤 to make the Winter a bit better :heart:

On each show, there will be one or more expert developers in any specific platform and we will do live-coding and/or discussions based on that particular technology/library/framework.

We will go LIVE on Youtube so that every one of you can interact in realtime and ask questions on the go.

I already have a few guests in the queue for the Podcast from different countries.

I have been working as a professional Software Engineer for the last 9 years and I know from my experience where most developers struggle most. So We will try to touch those bottlenecks which would really help developers.

It will be a super awesome show. :clap:


[<h3>Please SUBSCRIBE to the Youtube Channel here :point_right:</h3>](https://www.youtube.com/channel/UCy5EgfydCQlVv_AM-FZyYcg)


{% youtube PtaziLK3xZE %}



[<h3>Please also LIKE the Facebook Page here :point_right:</h3>](https://www.facebook.com/the.destro.dev.show/)
Back to Basics
Tags: discuss
Published: 2019-11-25 18:49:08

---
title: Back to Basics
published: true
description: 
tags: discuss
---
I have been in software industry for some time. However there are times, where I feel like going through basic concepts again.

Example: 
Basic sorting, search algos
Stacks/Queues/Trees 
4 pillars of OOPS 
Refactoring 
REST

Does anyone feel the same? How often do you go through such topics again? ✋
Most importantly, why you do it?
Arcology Roguelike Lifestream E6
Tags: unity3d, roguelike, livestream, gamedev
Published: 2019-11-25 17:55:01

`Scheduled for 25/11/2019 18:30 GMT`

# Episode 6: Procedural Generation

## Planned

* Add a loading bar
* Try and fix the procedural generation so that doors/openings match up
* Add camera controls
* Add basic MouseClick interaction

## Link and actually completed work

{% youtube P7lTCbVg7Uk %}

* Loading text added
* Spiral procedural generation implemented. Needs quite a bit of work, but it's looking much better
* Camera controls added

## Still to do from this session

* Fix camera rotation
* Fix procedural generation
* Add MouseClick interaction
A Programming Journey (VSCODE)
Tags: productivity, vscode, dotnet, beginners
Published: 2019-11-25 17:52:59

I've always been amazed by the always known (.NET IDE) that had been built by the well-known tech giant 'Microsoft' even tough I consider myself a GNU/Linux denfedor and Open Source advocate and contributor which I believe is the real truth of Computing and Computation. I can properly say that:

When it was originally Microsoft Visual Studio Code '20xx' it brings a lot of good stuff for you to customize the Development Environment and the helpfulness in which this Software was designed.

<h2> <b>VSCODE and the Magic<b> </h2>

Further than that. I am pretty much in love with how much with can do with VSCODE and the operatibility this software has transported thru the years. 

<h3> <b> Another Twist from Microsoft<b></h3>

<p> In my opinion. This new VSCODE is a lot different that it was old 'Microsoft Builds' It can magically powerful your productivity and plus it is FAST!</p>

<p> I am just <b>AMAZING</b> by the twist this Software just did. It went from just trying to compile a long-line text of codes and crash in the process to a fast saving easy just like a simple notepad. It blowed my mind how FAST the software became. Faster than the Roadrunner so yeah.

<p> You can just go ahead and test a Visual Studio old version and try out this new VSCODE you will notice the different <p>

<h2> <b> Code Productivity <b> </h2>

<p>When it comes to begin code most beginners fall in the tentation to do it all by Scratch. This is OK as long as it will teach you how the different components works in many different languages. However. When you realize doing all and ALWAYS by scratch it's not productivity and it won't help you in the long-run that's when you start to fall in love with the what I call 'Pre-Formatted Document' options that this <b> VSCODE has <b> It's just powerful.

<h2> Emmet Abbreviation (Formerly Zen Coding) </h2>

<p> If you have a HTML5 document saved and opened on the <b> VSCODE </b> you just type 'h' and it will popup to show up in emmet abbreviation some options to choose </p>

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/oxwmy8swzjnmk87j32g8.gif)

<h4> <b> Structure Selection </b> </h4>

<p> This awesome feature it's saving you a lot of time a headaches along the way while your coding. It is easy powerful and tasty to use </p>

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/f25m0no5lezoyir9n2py.gif)

<p> There is a lot more features that are available such as <b>Word replacing</b> if you have mystypo or incorrect syntax with a matter of a blink eye, you can turn out this in the correct word </p>

<h3> Hope you have enjoy the post. I will be looking to add updates a long the way </h3>
A better way of deploying Go services with Serverless Framework
Tags: serverless, go, aws, awslambda
Published: 2019-11-25 17:39:11

Go is a great language. I really like it. It's super simple, statically typed, with a huge ecosystem. It makes you [productive](https://medium.com/code-adventures/farewell-node-js-4ba9e7f3e52b). Do you know what's better than Go? An AWS Lambda function written in Go and deployed with _Serverless Framework_.

The experience of building Go services with Serverless Framework is not the best, though. Well, that's pretty obvious because the framework is language-agnostic. Let me list some of the issues:
- Go is a compiled language, so you cannot simply run `serverless deploy` or `serverless deploy function` after each code change because you need to compile it. It requires an intermediate step making the dev experience a bit disturbed.
- Developers that are new to Go don't know all the secrets of `go build` command. They tend to compile Go code without using addition flags causing the output file being larger than possible, which in turn causes the deployment process to take longer.
- When you define the function in `serverless.yaml`, `handler` property has to point to the compiled file, rather than to the source file. Again, not big of an issue, but it might be tricky for people starting with Go or/and Serverless Framework.


Usually, the solution is to have a `Makefile` or some Bash script that will automate the compiling and deploying process. But there is a better way.

## The Plugin

I really care about the developer experience, feedback loop, and about using well-tailored tools that make our work easier. That's why I would like to introduce you to [⚡️ Serverless Framework Go Plugin](https://github.com/mthenw/serverless-go-plugin)! 

{% github mthenw/serverless-go-plugin no-readme %}

The plugin solves all the aforementioned issues (and more!) and makes the development process seamless. Let see how it works.

Here is the [minimal](https://github.com/mthenw/serverless-go-plugin/tree/master/example) Go service:

```yaml
service: example-service

plugins:
  - serverless-go-plugin

provider:
  name: aws
  runtime: go1.x

functions:
  example:
    handler: ./functions/example/main.go
    memorySize: 128
```

No, let's deploy it:

{% asciinema 283470 %}

So:

- no reference to the compiled file because the plugin compiles the handler on-the-fly (concurrently on all CPU cores)
- no need to set `package` configuration excluding all unnecessary files from the zipped payload. The plugin does that for you.

The plugin also supports `serverless deploy function` and `serverless invoke local`! 

[Go check it out!](https://github.com/mthenw/serverless-go-plugin) If you have any questions let me know in [GitHub issues](https://github.com/mthenw/serverless-go-plugin/issues) or here in the comments.
Error Handling in Nodejs
Tags: node
Published: 2019-11-25 17:46:11

---
title: Error Handling in Nodejs
published: true
description: 
tags: #nodejs 
---
If any AsyncHook callbacks throw, the application will print the stack trace and exit. The exit path does follow that of an uncaught exception, but all 'uncaughtException' listeners are removed, thus forcing the process to exit. The 'exit' callbacks will still be called unless the application is run with --abort-on-uncaught-exception, in which case a stack trace will be printed and the application exits, leaving a core file.

The reason for this error handling behavior is that these callbacks are running at potentially volatile points in an object's lifetime, for example during class construction and destruction. Because of this, it is deemed necessary to bring down the process quickly in order to prevent an unintentional abort in the future. This is subject to change in the future if a comprehensive analysis is performed to ensure an exception can follow the normal control flow without unintentional side effects.
Features of Node.js
Published: 2019-11-25 17:42:32

---
title: Features of Node.js
published: true
description: 
tags: #react
---

Following are some of the important features that make Node.js the first choice of software architects.

Asynchronous and Event Driven − All APIs of Node.js library are asynchronous, that is, non-blocking. It essentially means a Node.js based server never waits for an API to return data. The server moves to the next API after calling it and a notification mechanism of Events of Node.js helps the server to get a response from the previous API call.

Very Fast − Being built on Google Chrome's V8 JavaScript Engine, Node.js library is very fast in code execution.

Single Threaded but Highly Scalable − Node.js uses a single threaded model with event looping. Event mechanism helps the server to respond in a non-blocking way and makes the server highly scalable as opposed to traditional servers which create limited threads to handle requests. Node.js uses a single threaded program and the same program can provide service to a much larger number of requests than traditional servers like Apache HTTP Server.

No Buffering − Node.js applications never buffer any data. These applications simply output the data in chunks.
UnityのWebGLビルドはWeb Server for Chromeで簡単に確認できるよ
Tags: webgl, unity3d
Published: 2019-11-08 09:16:00

---
title: UnityのWebGLビルドはWeb Server for Chromeで簡単に確認できるよ
published: true
tags: WebGL, Unity
date: 20191108T09:16Z
canonical_url: https://qiita.com/shiena/items/d5bc13a97c4d06b53072
---
# はじめに

UnityでWebGLビルドした時にさくっとブラウザで確認したいものですがChromeはセキュリティの関係でローカルファイルを開いても動作しません。
以下の解説のように`-allow-file-access-from-files`を起動時オプションに渡せば回避できますが常駐しているChromeを終了させなければならなかったりと面倒です。

* [Chrome でローカルファイルを読み込むためにセキュリティポリシーを回避する方法](http://neos21.hatenablog.com/entry/2018/01/06/080000)

そこでChromeから簡易Webサーバーを起動できる[Web Server for Chrome](https://chrome.google.com/webstore/detail/web-server-for-chrome/ofhbbkphhbklhfoeikjpcbhemlocgigb)を使えばさくっと確認できるので紹介します。

# 使い方

1. Chromeのブックマークバー左端のアプリからWeb Serverを開きます。

    ![image.png](https://dev-to-uploads.s3.amazonaws.com/i/ew805ok3qgbh9ct602xb.png)
    ![image.png](https://dev-to-uploads.s3.amazonaws.com/i/xorad4179o3eq9yt82q8.png)
1. 設定画面が開くので`CHOOSE FOLDER`からWebGLビルドしたフォルダを選択します。
1. Web Serverのスイッチをオンにしてサーバーを起動します。
1. `http://127.0.0.1:8887`のリンクをクリックします。

    ![image.png](https://dev-to-uploads.s3.amazonaws.com/i/2zfrrwovnt0ko87jwtrx.png)

以上の手順でWebGLビルドしたページをChromeで確認できます😊

# リンク

* [Web Server for Chrome](https://chrome.google.com/webstore/detail/web-server-for-chrome/ofhbbkphhbklhfoeikjpcbhemlocgigb)
* [Chrome でローカルファイルを読み込むためにセキュリティポリシーを回避する方法](http://neos21.hatenablog.com/entry/2018/01/06/080000)