teleren/devto huggingface dataset:
Usando testes de vagas para estudar
Published: 2020-11-03 18:47:05

Bom recentemente venho buscando maneiras de estudar para me aprofundar mais nos meus conhecimentos e descobri um [Github](https://github.com/felipefialho/frontend-challenges) com vários repositórios de testes para vagas de emprego, de certa forma é bom estudar assim, pois você vê como seu nível está e ao mesmo tempo pratica vendo como estaria para o mercado de trabalho.

Pra mim em particular tem sido muito vantajoso de estudar assim além de me preparar para poder aplicar em vagas eu acabo me forçando a correr atrás de certo conteúdo para poder concluir os testes.

Por exemplo recentemente fiz um teste para [react-native](https://reactnative.dev/) com [firebase](https://firebase.google.com/?hl=pt-br), vou resumir o teste era para criar um login usando firebase, eu nunca havia usado ele até o momento do teste, então fui forçado a garimpar a internet atrás de conteúdo sobre o banco da google. 

Demorei um bom tempo para concluir o teste por conta de estar aprendendo algo novo mas no final eu conclui o teste e aprendi muito com isso, infelizmente não passei na vaga mais agreguei conhecimento em algo novo realizando o teste.

Por isso decidi estudar aplicando para vagas de emprego, depois de ver um repositório do [m7he4rt](https://github.com/m7he4rt/alguma-coisa-de-pokemon#conhecimentos-necess%C3%A1rios-godmode) no qual ela fazia um teste da [RedFox](https://github.com/RedFoxTech) no qual eu decidi realizar o mesmo teste para iniciar meus estudos, aos poucos vou escrevendo sobre o teste, mas caso queira acompanhar mais de perto confira o meu [repositório](https://github.com/renatoReboucas/teste-backend-pokemon), bom espero que a idéia seja útil para vocês.
My Hacktoberfest
Tags: hacktoberfest, github, opensource
Published: 2020-11-03 18:35:50

### My first Hacktoberfest & I made it...
<!-- If you are new to the DEV community, introduce yourself and share a bit about why you joined DEV and decided to participate in Hacktoberfest this year.  --> 
### Background
I am a student of ECE and love doing programming stuffs, more specifically I like doings things that eases our everyday life. I am fond of Internet of Things and currently trying to learn it as much as I can as a fresher. I am in love with Python, also I web development is a part of my hobby.

<!-- Are you brand new to open source? What about coding in general? Tell us about how you got here →

### Progress
I am very new to open source, as a contributor. I already used open source software lots of time. But first time I did my contribution. Actually, for a project I used Digital Ocean, from there I first heard of the fest. But I came to know in details when my fellow classmates of my college took part and our rotary club made a webinar on it. But still I got into it merely because of the reward as it is itself a recognition. But it was the time of late octobers, and I rarely found any hacktober hosted repos on github that I can contribute. But luckily I found one on python. And I got into it. But still I wasted 4-5 hours to know how to get into there, but luckily, everything happened properly & I made it. 

<!-- Share a bit about where you’re at in your Hacktoberfest journey. What stage are you at? How has the process been?  -->

### Reflections
<!-- Overall, how has your Hacktoberfest 2020 experience been? If you’re a first-timer, will you participate again? What have you learned? Have you made any interesting connections? What is your next step in open source?  -->
Hacktoberfest gave me thrills, literally. It literally taught me how to contribute in open source projects and I found its power. I literally felt it like a competition and race against time to do as much as possible, but it was fun all through.
Hacktoberfest 2020 Done!
Tags: hacktoberfest2020
Published: 2020-11-03 18:31:57

---
title: Hacktoberfest 2020 Done!
published: true
description: Hacktoberfest accomplished
tags: #hacktoberfest2020
---

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/bs78mxks2iv10gcxj1js.jpg)
Day 3 with html/css and Javascript #100daycode
Tags: 100daysofcode, webdev, html, css
Published: 2020-11-03 18:23:25

So today I learned more abt css grid and flex box. And I worked with my portfolio,and updated a new card to site displaying my project. I haven't done any major code today but I'll compensate that tomorrow. But in my challenge I've learned regarding #web so it's a win win for me🥴.
The 7 Most Popular DEV Posts from the Past Week
Tags: top7
Published: 2020-11-03 18:23:11

---
title: The 7 Most Popular DEV Posts from the Past Week
published: true
description: A round-up of the most-read and most-loved contributions from the community this past week.
tags: icymi
cover_image: https://thepracticaldev.s3.amazonaws.com/i/sfwcvweirpf2qka2lg2b.png
---
Every Tuesday, we round up the previous week's top posts based on traffic, engagement, and a hint of editorial curation. The typical week starts on Monday and ends on Sunday, but don't worry, we take into account posts that are published later in the week. ❤️

### **Knowledge-retention is a superpower** 

... and @aurelio has a few tricks to achieve it. 

{% link https://dev.to/aurelio/how-i-remember-everything-i-learn-19mi %} 

### **Building a site quickly without compromising quality**

@gmlunesa walks us through the process of updating their personal website with an emphasis on speed *and* quality. Spoiler: the end result is fast, secure, inexpensive, and SEO-tastic. 

{% link https://dev.to/gmlunesa/how-i-developed-and-deployed-my-optimized-website-within-a-day-357l %} 

### **Why coding is worth it anyway**

@thawkin3 gives an honest and vulnerable look at some of the struggles of learning to code -- and why they would choose this path again in a heartbeat, regardless. 

{% link https://dev.to/thawkin3/i-wish-i-never-learned-to-code-lfe %}

### **“Imagine you’re a cat...**

… who is obsessed with potato chips, and has no idea what data science is.” You got me hooked, @orthymarjan!

{% link https://dev.to/orthymarjan/data-science-for-cats-1d7k %}

### **Remote work, works — here’s why you shouldn’t compromise your pay for it**

@hrishikesh1990 shares a super compelling look at why remote workers deserve to be paid a premium. I couldn’t agree more!

{% link https://dev.to/hrishikesh1990/forget-pay-cut-give-me-a-raise-to-work-remotely-32ep %}

### **An overlooked, fundamental skill**

@annajmcdougall walks us through the art of giving a great compliment and why we should do it more. Great post, Anna!

{% link https://dev.to/annajmcdougall/how-to-give-good-compliments-4ggl %}

### **Secrets are sneaky** 

Here’s how to deal with them securely and properly when it comes to Docker images. Thanks, @gasparev!


{% link https://dev.to/gasparev/advanced-docker-how-to-use-secrets-the-right-way-1l67 %}


_That's it for our weekly wrap up! Keep an eye on dev.to this week for daily content and discussions...and if you miss anything, we'll be sure to recap it next Monday!_
How to remove the # symbol from your Vue Router website url.
Tags: vue, vuerouter, javascript
Published: 2020-11-03 18:20:58

If you are building a Vue app, you may quickly notice that your app has a # symbol in your URLs. 

This is there for the browser "to simulate a full URL so that the page won't be reloaded when the URL changes."

Normally though, you don't want your URLs to look like that. It just looks messy.

In order to quickly remove the # symbol from your URLs, within your index.js file where you create a new Vue Router instance, add the history mode setting to it.

This is what this looks like:

```javascript
import Vue from 'vue'
import VueRouter from 'vue-router'

const router = new VueRouter({
  routes,
  mode: 'history' // Here is where you need to add the history setting mode.
})

export default router
```

Now, you are using the browser's history mode, and your links will utilize the history.pushState() API so that you won't have to do a full page load on new pages.

One caveat as the [Vue Docs describe](https://router.vuejs.org/guide/essentials/history-mode.html#example-server-configurations) is that if a user accesses a page directly from a link, your server will show a 404 page, and that is not wanted! 

To solve that, make sure your server is set up to send catch-all URLs to your Vue instance so that your users won't hit 404's.
Best way to using vue-clickaway in Nuxt.
Tags: nuxt, vue, javascript, clickaway
Published: 2020-11-03 18:12:00

In this article, I will show you to the best way of using vue-clickaway package in nuxt project.

First of all, if you are need to use this package in only one place you can just use it regular way as in the documentation.

But if you have a big project and you will use so many places you should see this usage.

Firstly you should install vue-clickaway.

```html
yarn add vue-clickaway
```
After that, we will create a nuxt plugin. Let's give it a name like `clickaway.js`. It's totally up to you.

We will use vue's Global Mixin feature for using the vue-clickway to global. You can take a look to [docs](https://vuejs.org/v2/guide/mixins.html#Global-Mixin).

Lets add the following code to our `clickaway.js` file.

```javascript
import { mixin as clickaway } from 'vue-clickaway'
import Vue from 'vue'

Vue.mixin({
  mixins: [clickaway],
})
```

Finally, we should register this plugin to our `nuxt.config.js ` file.

```javascript
 plugins: [
    '~/plugins/clickaway',
  ],
```

And our clickaway plugin is ready to use. You can use it anywhere you want in your project like in the example.

```html
<div v-on-clickaway="closeMenu">
    <h1>Some text...</h1>          
</div>
```

See you on the next tip. Have a nice coding ✌️
The CSS Series - Part 2: How to Link a Stylesheet to Your index.html File
Tags: codenewbie, css, html
Published: 2020-11-03 18:11:31

*This is Part 2 in a multi-part CSS educational series developed for the #vetswhocode non-profit coding boot camp. Follow @nbhankes and [@vetswhocode](https://twitter.com/vetswhocode?lang=en) to get notified when then next part of this educational series is released.*

*Expect the following parts in this series to serve as valuable reference material for your development career.*

### Some of the topics to look forward to are:
- Connecting the CSS style sheet to the index.html file
- Box Model
- Selectors
- Specificity
- CSS Units
- Flexbox
- Grid Layout
- Mobile First Design
- CSS Variables
- & more

## Introduction
This page will show you how to link a CSS style sheet with an HTML file. By linking these files, the style sheet will be able to access the content within the linked HTML document. This access allows web developers to use CSS selectors to begin altering the ways in which the layout of the linked HTML document renders on the browser.

## Prerequisites
Code editor (VS Code)
A Basic Understanding of HTML

## Setting Up The Project
Create a new project folder on your computer. Name it something like "CSS Practice." Open the empty folder in your code editor and create an index.html file and a stylesheet.css file. Your folder should be arranged like so:

 📂CSS Practice
  ┗ 📜index.html
  ┗ 📜stylesheet.css

Great. Now insert the following code into the index.html file:

```html

<!DOCTYPE html>
   <html lang="en">
      <head>
         <meta charset="UTF-8">
         <meta name="viewport" content="width=device-width, initial-scale=1.0">
         <title>Document</title>
      </head>
    
      <body>
  
      </body>

   </html>
  ```
  
The above code is a basic beginning skeleton of an HTML project. In order for your index.html file to link to the stylesheet.css file, you must supply a link tag to the HTML head tag. The following link must now be inserted between the HTML link tags:

```html
    <link rel="stylesheet" href="stylesheet.css" />
```

The link tag element establishes the file relationship "rel" as "stylesheet," ensuring the browser knows what the link is for. And the "href" attribute gives the stylesheet.css location in relationship to the index.html document. This tells the browser where to find the style sheet. In this example, the stylesheet.css and index.html files are in the same folder, so only the file name is required.

Your HTML code should now look like this:
```html

<!DOCTYPE html>
   <html lang="en">
      <head>
         <meta charset="UTF-8">
         <meta name="viewport" content="width=device-width, initial-scale=1.0">
         <link rel="stylesheet" href="stylesheet.css" />
         <title>Document</title>
      </head>
    
      <body>
  
      </body>

   </html>
  
```
  
## Conclusion
You just learned how to link a style sheet to an HTML file.
Python Dunder Magic 🐍
Tags: python, programming, dunder, codekaro
Published: 2020-11-03 17:46:11

Dunder methods in Python not only helps in operator overloading, but it gives the power to instantiate a class however we want (talking about __new__ method).

In my opinion, most important “Dunder” or “Magic” methods that everyone should consider while building a class are:

✔ __new__
✔ __repr__
✔ __getattr__ and __setattr__
✔ __iter__ and __next__
✔ __enter__ and __exit__

What are some of your most commonly used dunder methods that you consider while designing a class ?
Have you ever tried cloud development?
Tags: watercooler, productivity, development, remote
Published: 2020-11-03 17:42:23

---
title: Have you ever tried cloud development? 
published: true
description: 
tags: watercooler, productivity, development, remote
cover_image: https://blog.equinix.com/wp-content/uploads/2015/05/cloud-680px.jpg
---
Using a local environment might be the traditional approach for most devs, tho, depending on your needs, it might come with some downsides.

* Maybe you are working on different machines and tired of forgetting to pull and push, syncing data between the remote and local repos?
* Or the machine you work with simply do not have enough resources to do some highly CPU and RAM demanding stuff?
* Or you want to try different OS architecture without the need to affect the local machine you are working from?

Developing on a remote environment can solve all of these as the code is stored on a server and you can access it via your code editor / IDE.

This way, wherever you are, and how many machines are you using, you are always working with the same projects and you don't have to worry about syncing. Here's a [quick tutorial](https://www.youtube.com/watch?v=9Emn2YQNDl0) on how to set up VS Code in the cloud.

Have you ever tried this approach and would you recommend it? Any cloud hosts with great price/value ratios for this?
Node.js Crash Course - Part 6 - Express Apps
Published: 2020-11-03 17:34:40

#1. Installing Express
`npm install express` will install the required 'express' package locally.

#2. Creating Express App
```
const express = require('express');
const app = express();
app.listen(3000);
app.get('/', (req, res) => {
    res.send(`<p>this is a very nice paragraph of index page</p>`)
})
```
* `const app = express()`: This is our express app
* `app.listen(3000)`: By this line our app listens to port number 3000, and automatically the host is localhost
* `app.get()`: The `get()` method is used to handle a *get* request
* `res.send()`: automatically detects the content header, and automatically assigns the correct status code. We manually can also do that, but not mandatory.

#3. Routing and HTML Pages
```
app.get('/', (req, res) => {
    res.sendFile('./views/index.html');
})

app.get('/about', (req, res) => {
    res.sendFile('./views/about.html');
})
```
But this is not going to work.
The file path in `sendFile` should be a absolute path OR if it is a relative path then we have to specify the root path. The above do not work and the following code works.
```
app.get('/', (req, res) => {
    res.sendFile('./views/index.html', { root:__dirname });
})

app.get('/about', (req, res) => {
    res.sendFile('./views/about.html', { root:__dirname });
})
```


#4. Redirects
```
app.get('/about', (req, res) => {
    res.sendFile('./views/about.html', { root:__dirname });
})

app.get('/about-us', (req, res) => {
    res.redirect('/about');
})
```
`res.redirect('<route>')` this automatically sets the content header and status code and redirects to the redirected route.

#5. 404 Pages
```
app.get('/', (req, res) => {
    ...
})

app.get('/about', (req, res) => {
    ...
})

app.use((req, res)=>{
    res.sendFile('./views/404.html', { root:__dirname });
})
```
`app.use()` will be fired for every request if it reaches till this function.
Express executes the file top to down.
```
app.get('/', ...);
app.get('/about', ...);
app.use((rq,rs)=>{});
```
first it will check app.get('/'),
if not match, then app.get('/about'),
if not match, then app.use();

**So where we place the `app.use()` is very important**. For example:
```
app.get('/', ...);
app.use((rq,rs)=>{});
app.get('/about', ...);
```
In the above code block '/about' route will never be encountered. As soon as the request will reach `app.use()` this will return the response
First open-source experience during Hacktoberfest 2020
Tags: hacktoberfest, javascript, opensource, programming
Published: 2020-11-03 17:26:01


### How did I Hacktoberfest my October
I have joined Hacktoberfest 2020 only because I have reached out to a friend who I have met during WarsawJS workshops. The reason why I have reached out was to congratulate him on the anniversary of working in xFAANG and ask how is life.
As it turned out, my friend is well and quite happy about his career and asked if I will be taking part in Hacktoberfest 2020. I had no idea Hacktoberfest exists, so I checked the website and so it started :D

### Contributions
All contributions were possible thanks to the help of Marcin Hagmajer and Yonatan Kra :)

1. First open-source contribution in my career https://github.com/xFAANG/askql/pull/523
2. Longest Pull Request with many attempts to accomplish the objective :D https://github.com/xFAANG/askql/pull/526
3. Github feature request issue template PR https://github.com/xFAANG/askql/pull/525
4. Github bug issue template PR https://github.com/xFAANG/askql/pull/528


### Reflections
Overall, my Hacktoberfest experience was challenging but enjoyable. Especially when my changes were merged and Yonatan [has used them in his programming tasks](https://twitter.com/YonatanKra/status/1321678137562959872?s=20) :)

This experience brought new friendship and new experience and I will definitely participate in Hacktoberfest 2021!

Anyone else planning to join next year?
Vestigo v0.5.0 - Tales of Port Scans
Tags: security, news, devops, javascript
Published: 2020-11-03 17:19:18

# Introduction

After other side projects and less free time I had to leave Vestigo for a while

{% link https://dev.to/crimsonmed/discovering-vulnerable-endpoints-on-api-websites-67g %}

With Hacktoberfest I decided to revisit this project and start to make it into something useful. When doing simple API tests I find myself often repeating the sames tasks. 

- NMAP on the target 
- Rust Scan
- DirBuster
- And more

The idea of Vestigo is to have a one tool that does all this with ease.

# v0.5.0

## Scan

Since the last update on Vestigo on dev.to there have been a few updates to the Scan command. It will now save reports in HTML and MD.

Those reports will be saved on the user profile `~/.vestigo`

The scan comes with a whois module

## Ports

v0.5.0 introduces the ports command which lets you portscan a target that is either an ip or a domain.

As of now only TCP scan has been integrated. But I plan to add UDP + reporting for this module.

I also want to add the possibility to try to curl the ports that possibly have a webserver. And in the future be able to detect the stack (wordpress, react, etc.)

![port scan](https://dev-to-uploads.s3.amazonaws.com/i/rnjpz9ux4f5tw3pg0sja.png)

Example command:

```bash
vestigo ports --target="127.0.0.1"
```

# Going forward

The project is open source and on github so anyone wanting to participate in the development of this tool don't hesitate to open an issue based on the TO-DO list in the README.md with what you would like to tackle.

I hope this project can help many and that it can find some support and love.

{% github https://github.com/crimson-med/vestigo %}

---

Burlet Mederic
https://medericburlet.com
https://mederic.me
https://twitter.com/crimson_med
My First Hacktoberfest — Experiences of Contributing to Open Source
Tags: hacktoberfest, opensource
Published: 2020-11-03 17:18:18

Contributing to Open Source and projects can seem like a daunting process. Your favorite search engine will return a ton of results on guides and repositories to get started. But many times, your search does not yield the result you want, you still do not know how to contribute to Open Source even after reading multiple blog posts. The impeding reputation of certain projects and a harsh undertone does not help either and might complicate matters even further.

I have been there myself. I trawled through pages to find great Open Source repositories to contribute to, only to notice that I did not know how to start.

Frustrated and a little disappointed, I started focusing on other projects instead.

But it all changed when I saw a fellow employee’s Hacktoberfest sticker on their laptop. I was intrigued — was this a remnant of yet another Hackathon?

Hacktoberfest turned out to be very different.

### So what is a Hacktoberfest exactly?
Hint: it doesn’t have to do with either beer or hacking or the Oktoberfest (which actually takes place in September, duh!).

[Hacktoberfest](https://hacktoberfest.digitalocean.com/) is a month-long celebration of contributing to Open Source, running from 1st October to 31st October. It was initiated by DigitalOcean in collaboration with GitHub. During the month of October, you are encouraged to contribute and make pull requests to your favorite repositories on GitHub. If you manage to make four in total, you are eligible to receive a swanky T-Shirt.

### What can we take away from this?
I would advise you to free yourself from the assumption, that you need to contribute perfect and well-rounded code the first time. Your first contribution does not have to be ground-breaking (or even be code to be precise).

### Conclusion
If you have the experience of contributing to open source, please share it in the comments. **Happy Coding!**
Method naming conventions I use to either merge or replace the instance values
Published: 2020-11-03 17:08:21

Lets say I have an instance variable in a class that holds an array of strings
```
private $scopes = [];
```

To merge given scopes into existing scopes
```
public function scopes(array $scopes)
```

Completely replace scopes array with new items
```
public function setScopes(array $scopes): void
```

Get the current scopes
```
public function getScopes(): array
```
Django Custom User Model ( AbstractBaseUser)
Tags: django, python, computerscience, webdev
Published: 2020-11-03 17:01:39

Hello, 

Anyone have any referenceor book about Django custom user model? I am find it very difficult as a beginner would you please suggest me any reliable resource or video or book where i learn from it. I m using Abstract Base User for multiple users. 

Ps: dont suggest me Django official reference it is little bit hard for me tbh.