teleren/devto huggingface dataset:
A Importância de rever a biblioteca da Linguagem que você utiliza.
Tags: python, documentation, languageprogram
Published: 2020-07-19 19:54:44

# Quando você quer saber sobre uma coisa, o que você faz? 

Primeiramente devemos organizar um cronograma e saber como você funciona em estudos, ler e fazer a prática ou em um super mecanismos de: ver vídeo, fazer a prática e ler.

![First of all](http://1.bp.blogspot.com/-zrTlvETPMpE/TniyCyN-BJI/AAAAAAAAAJI/U18hqFXOD_w/s1600/tumblr_lquuyjOhYT1qdcxm3o1_400.gif)

1. Escolha aquela linguagem do qual você esta aprendendo, no meu caso o Python.
  * Entenda o básico
  * realize as práticas e lembre-se de documentar, comentar o que você esta fazendo, assim você consegue fixar bem os comandos.
  * Segundo, leia, procure as documentações, pois muitas vezes você pode não se dar conta das novas atualizações da linguagem.

No meu caso, eu gosto de começar do zero, baixo pdf e aprendo meio que autodidata e isso até com idiomas( Grego e agora Francês que estou aprendendo como Hobby). 
Por isso que disse que aprender vai de cada um, e nem todos são da mesma forma de estudo.

# Mas Jeh, onde você quer chegar com isso?

Atualmente eu estudo a linguagem Python, faço parte do PSF, e vejo o que mudou nas documentações, realizo alguns testes e vejo a performance de alguns resultados. As vezes as atualizações acontecem quando atualizamos uma nova release, e muitos não gostam pelo novo método de escrever o código. Pode ser péssimo, mas na vida sempre estamos sujeitos a mudanças e aprendemos algo novo, e sentimos como o Neo no Matrix.

![I know Kung fu](https://media.giphy.com/media/3o7btNhMBytxAM6YBa/giphy.gif)

Vejamos a um exemplo aqui que eu dei no fórum de dúvidas:
Antigamente tínhamos a forma de imprimir a mensagem
```
cor_vestido = 'vermelha'
cor_sapato = 'marrom'
print 'O vestido da menina é %s e sapato %s' % (cor_vestido, cor_sapatos)
```
Depois de um tempo mudou:
```
print ('O vestido da menina é %s e sapato %s' % (cor_vestido, cor_sapatos))
```
E hoje lembra um pouco de JS, mas não tanto...

```
print (f'O vestido da menina é {cor_vestido} e sapato {cor_sapatos}')
```
Mas lembrem-se, a cada nova release é bom dar uma olhada das documentações, como agora, tem dois rascunhos para atualização do Python 3.9 e 3.10.
Vejamos alguns:
 * Mesclar dicionário e dar update
 * Datetime - isocalendar()de datetime.date e isocalendar()de datetime.datetime métodos agora retornam um namedtuple()em vez de um tuple.
 * As visualizações retornadas por dict.keys(), dict.values()e dict.items()agora todas, têm um mappingatributo que fornece um types.MappingProxyTypeobjeto que envolve o dicionário original. (python 3.10)

Descontinuadas:
* O random  atualmente aceita qualquer tipo Hashable como um valor de semente possível. Após Python 3.9, o módulo irá restringir - None, int, float, str, bytes, e bytearray.

[O que há de novo no Python 3.9](https://docs.python.org/3.9/whatsnew/3.9.html)

[O que há de novo no Python 3.10](https://docs.python.org/dev/whatsnew/3.10.html)

Logo faço sobre Pandas, Numpy e Jupyter.
Abraços pra todos
Um beijo, um queijo e um vinho!

Excelsior ☝🍀
std. made immutable.
Tags: deno, typescript, blockchain, arweave
Published: 2020-07-19 19:34:28

# TL;DR

https://nest.land/std

### First, what is nest.land?

Nest.land is an immutable alternative to deno.land/x. All modules published to the platform are uploaded to the Arweave Blockweave, where they can never be modified or deleted. This ensures that any (non-vendored) code **you** import into your Deno projects is available forever.

## Why Deno's Standard Modules?

Our platform already holds over 60 third-party modules and over 20,000 files. We're actively growing and expanding our community, but what would happen in the event of deno.land/std having a temporary outage or shutting down 30+ years from now?

Deno's Standard Modules are a critical piece of the pie. Without these modules, developers would have a very difficult time building Deno applications and using Deno to its full potential.

In light of Deno's love for decentralization, all standard modules have been published to Arweave, where they can be hosted and served from 347 individual nodes and counting. 

Before you ask: "Well, what if nest.land goes down? What then???"
> We'll be rolling out alternative import urls shortly that import code **directly** from Arweave's Permaweb Gateway. This way, even if nest.land has an outage, std will not.

## Try it out!

Check out https://nest.land/std to see our brand new Standard Module Gallery. You can use this std mirror as an alternative to deno.land/std.

From now on, we'll be publishing each new version of Deno's Standard Modules on [nest.land](https://nest.land)!

> Note: Nest.land is not in its `1.0.0` stage yet, so bear with us if you find a bug or something not working as expected. We are actively working to mitigate issues and maintain stability!

<hr />
Feel free to join our [GitHub Discussions](https://github.com/nestdotland/nest.land/discussions) or report issues on our [repository](https://github.com/nestdotland/nest.land)!

### Special thanks:

@lucacasonato
@caspervonb
@ry

[#6699](https://github.com/denoland/deno/issues/6699)
Terminal split-screen recording with asciinema + screen
Tags: tutorial, screenrecording, shell
Published: 2020-07-19 19:11:38




While showcasing [geo2tz](https://dev.to/noandrea/ready-self-hosted-geo-to-timezone-service-1ee0) I wanted to record both client and server on the same [asciinema](https://asciinema.org/~noandrea) video.  

Luckily you can do just that using [screen](https://linux.die.net/man/1/screen).

> I'm assuming at this point that you have installed both `asciinema` and `screen` and that you are on linux.

**Before you start**, add this line `layout save default` in your `~/.screenrc`

Next setup your screen session so when you are about to record the screen will be already set:

```
screen -R devto 
```

Once there execute this sequence of keystrokes (case sensitive): 
- `ctrl` + `a` + `S` // split horizontally
- `ctrl` + `a` + `Tab` // move to the bottom window
- `ctrl` + `a` + `c` // open a new shell
- `ctrl` + `a` + `Tab` // move back to the top window
- `ctrl` + `a` + `d` // detach (but not close) the session

> pro tip, for maximum effect you can set the windows name with `ctrl` + `a` + `A`

Now that the stage is ready you can start recording:

```
asciinema rec -c "screen -R devto"
```
Here is how it looks like: 

{% asciinema 346460 %} 

> if you don't see the embed, follow [this link](https://asciinema.org/a/346460) to the video.

Do you know another way of doing this, maybe with tmux?
Introduction
Published: 2020-07-19 19:09:15

Hello Dev!

I'm Shelby. I've been lurking for some time and finally decided to take the plunge and introduce myself.

Dev has been the perfect place for me to learn and to explore technologies, opinions, tutorials, etc. I consider myself to be a multipotentialite--essentially, I have experience in various things vs being an expert in one thing.

I am an IT & Business Analyst as well as an Adjunct Professor--I teach undergrads in the business school about technologies they will and can use. 

In addition to my day jobs, I'm a blockchain evangelist and a cryptocurrency investor. I've started learning the Ethereum coding language, Solidity, and am working with a friend to create our first Dapp.

My additional areas of interest include data analytics, artificial intelligence, Python, ReactJS--I'm relearning it now, privacy and security, UX/UI, and more.

My goals are to start writing about what I'm learning. They say the first step is always the hardest and it's taken me some time to post this. Step 1 - Done! 

I look forward to meeting you.

Best,
Shelby
C
Published: 2020-07-19 19:03:03

Just six months into software development and the major lesson/advice I'll carry with me was "grow your developer community do not be limited to one dev community". I started with Bootcamp training at Lakehub Academy, Kenya;
* covered part of Freecodecamp curriculum and interacted with their community on twitter and general tech twitter influencers;
* joined hng internship and interacted with good number of designers , developers and mentors;
* I'll be joining WeJapa internship from tommorow hoping to gain and learn more from its community;
JS Bits - Array Methods
Tags: javascript, beginners, webdev
Published: 2020-07-19 18:28:36

# Welcome to JS Bits

Hello everyone, welcome to the first post on my new series JS Bits where I explain and also show you use cases where you can use them. 

This post was originally posted on my [blog](https://sedat.dev/blog/).

Find it [here](https://sedat.dev/blog/js-bits-array-methods/)

## Array Methods

### Array.prototype.find(callback)

Takes a callback function that returns the value of the first element that satisfies the condition.

```js
const arr = [5, 12, 8, 130, 44, 130];
const found = arr.find(element => element > 50);
// found is equal to 130. It found the value 130 in the third index and returned it.
```


### Array.prototype.findIndex(callback)

Similar to find method, returns the index of the first value that satisfies the condition

```js
const arr = [1,2,3,4,5];

const isLargeNumber = arr.findIndex((element) => element > 3); // return the index of value 4 which is 3
```

### Array.prototype.includes(valueToFind[, fromIndex])

Returns `true` or `false` whether the array includes the given value.

```js
const arr = [3,2,5,6]
console.log(arr.includes(5)) // returns true
```

As an optional argument includes takes a parameter fromIndex which means where to begin the searching for the valueToFind

```js
const arr = [3,2,5,6]
console.log(arr.includes(5, 2)) // starts searching the value 5 in arr beginning from the second index which returns true.
```

### Array.prototype.flat([depth])

Creates a new flattend array with all the sub-array (nested parts) values taken out and concentinated in to the higher depth.

You will understand it better with this example;

```js
// we have a nested array like this
const arr = [1,2,[3,4], 5, 6, [[7]] 
// this array has [3,4] which goes one level deeper and empty array of [[]] which goes two levels deeper
const newArr = arr.flat() // default value is one, returns the array: [1,2,3,4,5,6,[7]]
const otherARr = arr.flat(2) // goes to the depth of two and returns: [1,2,3,4,5,6,7]

```

### Array.prototype.flatMap(callback(currentValue[, index[, array]])

It is very common now to use functional programming or FP methods in JavaScript like map().

If you want to use `flat()` on an array you are mapping. You have to first `map()`, which creates a new array and then call the `flat()` method.

`flatMap()` combines a map and a flat with a **depth of one** by first mapping each element and then running flat on the newly created array.

```js
const arr = [1, 2, 3, 4];
const doubleArr = arr.flatMap(x => [x * 2]);
// [2, 4, 6, 8]
```

A very good use case of `flatMap()` is adding or removing items during a `map()`.

```js
const returnDoubles = [1,2,3,4,5,6].flatMap((v) => {
	if(v % 2 === 0) {
        return [v];
    } else {
    	return [];
    }
})
// [2,4,6]
```

Keep in mind that if you want to run `flatMap()` with a depth different than one(1). You have to call `flat()`
additionally with a `map()`.

Want to learn more about me? Here's my [portfolio](https://sedat.dev)
Interactively Browse Large Lists of Data with FZF
Tags: commandline, fzf, tutorial
Published: 2020-07-19 18:55:39

When faced with a large list of output data, I often reach for `grep` to narrow down the results. This can help me find what I'm looking for, but it often involves a little trial and error.

We can enhance this process by making it interactive. [`FZF`](https://github.com/junegunn/fzf), a fuzzy finding utility, is the perfect tool for the job. It is speedy, composable, and smart.

In this quick video from my [Modern CLI](https://www.youtube.com/playlist?list=PL46-cKSxMYYApfLRGEGZT57KBD4xg93cz) series, I show how `FZF` can be used to interactively narrow down the list of installable package versions output by [`asdf`](https://github.com/asdf-vm/asdf).

{% youtube mdUUWDr7SIU %}

## The Details

I needed to find a version of Node.js to install on my machine, but I wasn't sure what was available. Because I use `asdf` to manage my version of Node, I used the following command:

```bash
$ asdf list-all nodejs
```

This produced pages and pages of output in my terminal. Rather than trying to scroll up to the right spot or get a `grep` command just right, I decided to pipe the output to `fzf`.

```bash
$ asdf list-all nodejs | fzf
```

The results of the `asdf` command are fed into `fzf` which opens a prompt at the bottom of the terminal. I can type anything that might match the results.

For instance, what if I type `10` into the prompt.

```
> 10
```

This will narrow it down to everything that contains `10`. Because it is fuzzy, it will include results like `4.10.0`, `10.9.0`, and even `4.1.0`. The results are ordered by best match.

If I want to find Node versions that are major-version 10, then I can inject a little regex into my search term.

```
> ^10
```

The `^` character in regex means that the following atom (`10`) should be anchored to the beginning of the string. Now the results are just those under major-version 10.

I can narrow it further by adding in the minor version:

```
> ^10.1
```

And because this whole thing is interactive, I can quickly change the `0` to a `2`:

```
> ^12.1
```

to find major-version 12 packages.

This is just one example of interactively exploring a large list of output with `fzf`. Remember that you can pipe output from any command into `fzf`. Install `fzf` and give it a try.

---

There is more where that came from. If you enjoyed this post and screencast, [subscribe to my newsletter](https://tinyletter.com/jbranchaud) and check out the rest of the [Modern CLI series](https://www.youtube.com/playlist?list=PL46-cKSxMYYApfLRGEGZT57KBD4xg93cz).
how green threads can change multithreading core more efficient and easy in python 
Tags: python, gevent
Published: 2020-07-19 18:39:51

we all know thread handling is some times goes complex in python 

So gevent also knowns as green event or greenlet make your complex threads to execute in more simple way

here is my short tips that can help you 

https://youtu.be/QuLMDL1aRSo
Slack Clone #FlutterPen #CodePenChallenge #FlutterChallenge
Tags: codepen, dart, uiweekly, challenge
Published: 2020-07-19 18:36:49

<p>Hey Flutter devs 🙋‍♂️ Checkout this Slack clone web version I made as part of the Flutter CodePen Challenge.
😎 Week2 Challenge: Build a layout in Flutter.
🔗 Link: https://lnkd.in/gTDWU7F</p>

{% codepen https://codepen.io/nathanspen/pen/abdaRQr %}
iLRN 2020 VR Conference Production Design
Tags: design, productiondesign, econference, ilrn
Published: 2020-07-19 18:16:14

Remember that conference where there were respected speakers from immersive learning research and industry, vetted scientific and practitioner research presented in the flipped model, guided adventures as field trips...and hosted in at least 3 virtual platforms (VirBELA FrameVR AltspaceVR)? 
We do! Heather and Tiago eagerly put our hands to the work of making the dreams of ilRN 2020 become a reality. Here is a peek behind the scenes on the design of this amazing conference, and some of the decisions and details that made iLRN 2020 happen. 

Written together with Heather Dodds.

Read more about it here - https://www.linkedin.com/pulse/ilrn-2020-vr-conference-production-design-tiago-martins-peres-%E6%9D%8E%E5%A4%A7%E4%BB%81

 #design #productiondesign #econference #ilrn #ilrn2020 #virtualworld #vr #immersion #interaction #2020EdInVR #v2ec #lavalvirtual2020 #changemapping #expo #ea #virbela #asvr #framevr #mozillahubs #engagevr #discord #sched #youtube #twitch #zoom #tech #accessibility #engagement #remotelearning #code #community #trello #virtualconferences #edtech #education #business #virtualreality #VR #XR #AR #MR #EasyChair #timezones #serendipity
Discover Bulma - CSS Framework
Published: 2020-07-19 18:03:35

Bulma is a free, open-source CSS framework. The modern design and layout features that Bulma offers are very easy and simple to use. 

**Examples from Bulma.io.**
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/bvfg3y06cih3ceg5aajy.png)
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/3v6gatnr6vcu1mdzxy50.png)


#Several ways to get started with Bulma#

Use npm to install the Bulma package

`npm install bulma`

Use the cdnjs CDN to link to the Bulma stylesheet

https://cdnjs.com/libraries/bulma

Use the GitHub repository to get the latest development version

https://github.com/jgthms/bulma/tree/master/css
<hr>

**If you want to use icons with Bulma, don't forget to include Font Awesome 5**

```<script defer src="https://use.fontawesome.com/releases/v5.3.1/js/all.js"></script>```

#Bulma provides many great features like:#

**Flexbox based:** Makes creating grid items and vertically aligned things really easy.
**Responsive:** Mobile first framework similar to Bootstrap
**Solid looking foundation:** All the typography, buttons, tables, forms, and basic CSS
**Lot of components:** Comes with layouts, a vertical alignment level, and media objects.

Bulma is well documented which is very important.

#Modifiers
Modifiers classes allow you to set alternative styles to almost all of the Bulma elements. The Bulma syntax uses the `is-` keyword to identify modifiers on the base class. For buttons, `button` is the base class and there are modifiers like `is-primary`, `is-small`, and more.

*Here's some example form Bulma.io for buttons*
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/e4g9nqi9v344i58m67t0.png)
Check out more on the buttons at [Bulma.io](https://bulma.io/documentation/elements/button/).<hr>
#Columns
Bulma is based on Flexbox, so it’s really simple to create columns. First, we’re creating a container `<div>` with a class of `columns`, and then we give each of the children a class of `column`. Each column will have equal width, no matter the number of columns.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/wuvmk5exylay10vgoew9.png)<hr>
#Hero
The hero component allows you to add a full-width banner to your webpage, which can optionally cover the full height of the page as well.  To create a hero in Bulma. We’ll use the semantic `<section>`, and give it a class of `hero`. We also need to add a `<div>` child with the class `hero-body`.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/tz3exwsq1jb9ro7besxz.png)<hr>
Bulma is a great flexbox based CSS framework that has proven itself with the constant updates and new features. The modifier `is-` keyword is simple to use and also very readable. 

Give Bulma a try and definitely read through the [docs](https://bulma.io/) to see all the offerings.
Working With MongoDB
Tags: 100daysofcode, mongodb, javascript
Published: 2020-07-19 17:51:49

Lets review some of the interesting concepts i've learnt today on mongodb and API'S.

* Importing data.
Asumming we have data  in a dataJson.js file we can import this data to mongodb using `mongo students < dataJson.js`. Pretty easy!

* Next on the list is mongoose! 
Mongoose is a data modelling library that *handles all our database stuff for us so we don't have to deal with mongoDB directly ~Jonathan Mills.* We need to install it first using `npm install mongoose` from the terminal then include it in our js file. 
``` javascript
const mongoose = require('mongoose');
```
To set up a database connection we use the  mongoose connect method which takes one parameter - the link to the local mongoDB database. 

 ``` javascript
const db = mongoose.connect('mongodb://localhost/students');
```

* Creating a Model. 
A model is essential when reading, retriving or manipulating data in a database. To create a model we define a new schema and pass in an object with all properties and their data types.
```javascript
const mongoose = require('mongoose');

const {Schema} = mongoose;

const studentModel = new Schema(
  {
    firstName: { type: String},
    lastName: { type: String},
    major: { type: String},
  }
);

module.exports = mongoose.model('Student', studentModel);
```


End of day 3!
Looking for Resources
Tags: beginners, webdev, javascript
Published: 2020-07-19 17:39:13

Hi, I am an amateur programmer looking forward to learn new skills here and improve the old one . I have a good knowledge of HTML and CSS and i am looking forward to improve it and Dive into Javascript , But i am a bit confused about where and how to start and how to learn it . So i am looking forward for your help and suggestions.So your valuable tips and resources are always welcomed .
21 React js Interview Questions and Answers
Tags: react, javascript
Published: 2020-07-19 17:25:58

React js Interview Questions and Answers for experienced software developer

If you’re an aspiring front end developer and are getting ready for interviews, then this https://www.indiahires.in is for you. This blog on Top 21 Questions for React Interviews is the perfect guide for you to learn all the concepts necessary to clear an interview with React. But before we continue with the questions of the reaction interview, let’s take a quick look at the demand and status of React on the market.

The JavaScript tools are slowly and steadily firming their roots on the marketplace and the demand for React certification is exponentially increasing. It is becoming increasingly difficult to choose the appropriate technologies to create an application or website. React is considered by others to be the fastest-growing Javascript framework.


check all 21 questions here
1. Compare and contrast developing ES5 and ES2015 (also known as ES6) react components. What are the pros and cons of using one or the other? Include notes on default props, initial state, PropTypes and DisplayName.

2. Explain the Virtual DOM and how React renders it to the DOM?

3. Compare and contrast the different lifecycle methods used in the React Component. How might understanding these help build certain interfaces/features?

4. What is the difference between state and props?

5. How would you create Higher Order Components (HOCs) in React?

6. What is the significance of keys in React?

7. What is the use of refs in React?

8. What are pure functional Components?

9. How can React handle or restrict Props to some types, or require some Props to exist?

10. What is prop drilling and how can you avoid it?

11. What is the StrictMode component and why would you use it?

12. What is the important architectural difference between a JavaScript library like React and a JavaScript framework like Angular? Why does that impact the decision to use one or the other for a project?

13. If you required a component to perform an action only once the component was initially made, how would you do that with a class object? And how are you going to accomplish this with a function component?

14. What are the most common approaches to styling a React application?

15. If you were working on a React application that was rendering a page very slowly, how would you be investigating and fixing the issue?

16. What is useState() and useEffect() in React?

17. What is the difference between a controlled component and an uncontrolled component?

18. How are you going to differentiate Redux from Flux?

19. What is the use of render() function in ReactJS?

20. Explain Redux and its components?

21. Explain React.Fragment, React.lazy and Suspense?


If you want to check answers for the above questions, you can visit on my blogging site Indiahires.in.

My site link: https://www.indiahires.in/21-react-js-interview-questions-and-answers/