teleren/devto huggingface dataset:
Have you built a website with Gatsby?
Tags: javascript, webdev, discuss, gatsby
Published: 2021-01-04 08:46:31

Our team recently just rebuilt [our website](https://fingerprintjs.com/) in Gatsby and set up our first blog using Netlify CMS. The main reason for the switch was for faster performance and easier content management, and in that regard its been great so far!

Curious to hear your experiences using Gatsby and you have any tips and tricks for us:

* How was your experience using Gatsby (overall, compared to other static site generators)?
* What CMS did you use (if any)?
* Are you doing for AB testing on your site? We had some trouble out of the box with standard tools (Google Optimize), so curious what others have found worked well for them!
What are the types of regression testing?
Tags: regressiontesting, softwaretesting
Published: 2021-01-04 08:41:54

Regression testing is a black box testing strategy performed by executing units of code over and over again to guarantee that the on-going code changes don't affect the framework’s functionality. Changes to the application can happen in different structures, be it new functionality, bug fixes, reconciliations, usefulness improvements, interfaces, patches, and so on. Numerous software developers would demand that as long as basic capacities are tried and can convey results according to requirements, it would do the trick. While this might be practical, regression testing can demonstrate to be a genuine gift at a later stage, in light of the fact that instead of simply ensuring the usefulness being tried for, it guarantees that there are no other terrible bugs.

Types of Regression Testing 

Frequently, <a href="https://www.testingxperts.com/services/Regression-Testing/">Regression testing</a> is done through a few periods of testing. It is consequently, that there are a few sorts of regression testing. A couple has been referenced underneath: 

Unit regression – Unit regression testing, executed during the unit testing stage, tests the code as a solitary unit. It has a tight and centered methodology, where complex co-operations and conditions outside the unit of code being referred to are briefly blocked. 

Partial regression– Partial relapse is performed after-effect investigation. In this testing procedure, the new expansion of the code as a unit is made to connect with different pieces of more established existing code, so as to discover that even with code alteration, the framework capacities in storehouses as wanted. 

Complete regression – Complete regression testing is frequently done when the code changes for adjustment or the product refreshes leak route once more into the roots. It is likewise done in the event that there are different changes to the current code. It gives an extensive perspective on the framework all in all and gets rid of any unexpected issues. A kind of a "last" regression testing is actualized to confirm that the developer (new lines of code) has not been modified for a while. This last form is then sent to end-clients.

Conclusion
Regression testing enables the desired outcome enhancements. The demand for end-users to change or upgrade functionality is only dynamically enhancement. Software developers undergo several changes of coding when modifications are being made to the existing functions.
Is it worth to cross-post on Hackernoon in 2021?
Tags: discuss, hackernoon, writing
Published: 2021-01-04 08:33:59

---
title: Is it worth to cross-post on Hackernoon in 2021?
published: true
description: 
tags: discuss, hackernoon, writing
cover_image: https://mk0thetokenist81xfs9.kinstacdn.com/wp-content/uploads/2019/02/hackernoon-logo.png
---
I've cross-posted a couple of articles on [Hackernoon](https://hackernoon.com), just to see the idea of the platform and how it works.

I got concerned about the following reasons: 
* No API to automate the process; 
* Entirely different editor (compared to ones you see in DEV and Hashnode), that needs a lot of manual tweaking;
* I find the platform to be slow, takes around 5 secs to log in and another 5 secs to start writing (on a good connection);
* After submitting you go through up to 2 weeks waiting time, during which the editors of the site manually edit your article before publishing. 

On the other hand, the platform still holds quite an amount of readers, and the articles got well distributed by their social media strategy.

Thus the discussion, do you think it is still worth cross-posting your content on Hackernoon in 2021?
<lume-gltf-model> 3D model element (live demo)
Tags: lume, html, webgl, webdev
Published: 2021-01-04 08:19:54

New demo! One per day all 2021! Today I added a `<lume-gltf-model>` element to LUME, an HTML 3D toolkit.

It works similar to an `<img>` tag: just give it a `src` attribute to a file like so:

```html
<lume-gltf-model src="path/to/model.gltf"></lume-gltf-model>
```

{% youtube LcnBzqSwSA0 %}

{% codepen https://codepen.io/trusktr/pen/mdrxvVx %}

Made with LUME:
{% github lume/lume %}

topics: #threejs #webgl #css #javascript #webdev #graphics #365DaysOfCode2021
How to install bundler for Ruby < 2.3
Tags: rails, ruby
Published: 2021-01-04 08:16:49

You may get the following error when you attempt to install Bundler 2 with Ruby version < 2.3

```
ERROR:  Error installing bundler:
	bundler requires Ruby version >= 2.3.0.
```

In order to address this, we must update the ruby version of your project or set up the last supported Bundler version for Ruby < 2.3

```
gem install bundler -v '~>1'
```
Data Visualization as a service using the Digital Ocean App Platform - API documentation
Tags: dohackathon, node, digitalocean, hackathon
Published: 2021-01-04 07:59:26

Since a core part of my proposed submission is an API, it is important that I create a robust and concise documentation for how developers who want to create charts via API can go ahead with it. I have successfully created the first draft of the API documentation and I'm looking forward to your comments on the ease of use of the API. 

The API documentation can be found here: https://vaasapp.co/docs

I would appreciate your feedback on the clarity of the API documentation and suggestions on how to go about improving it. Thank you.

Also, in my previous article, I talked about how Puppeteer wasn't working on the app platform and how the Digital Ocean Engineering team is working on it, my response was to extract that core component of my submission to an external HTTP service and I've successfully implemented it. Now, you can seamlessly create data visualizations and extract the generated image via API without the app crashing. 

Thank you for reading. I'm looking forward to my final submission later this week and hopefully, my product submission would be a top contender for the grand prize and developers with non-developers can start paying for the service once we go out of the present beta testing phase that it is at the moment.
Write better console.logs in JavaScript 
Tags: javascript, debugging
Published: 2021-01-04 07:53:49

---
title: Write better console.logs in JavaScript 
published: yes
description: When debugging a problem it's important to see things clearly.  
tags: javascript, debugging
cover_image: https://dev-to-uploads.s3.amazonaws.com/i/q7s2chqwgzvhvqo60rac.jpg
---

I was answering some coding questions on Free Code Camp forums and noticed that in all the questions, people where just logging the variables like this: 

```
console.log(myVariableX) 
... ( a few more lines in between)
console.log(theOtherVariable)
```

This resulted in the logs like this: 

```
23.45
98
```

This does not help with figuring out what is happening. Specially if you are somebody who has jumped in to help quickly. 

**Always add a message to your console.logs!**

console.log can accept multiple strings: 

```
console.log('myVariableX:', myVariableX) 
... ( a few more lines in between)
console.log('theOtherVariable:', theOtherVariable)
```

This will result in logs like this: 

```
myVariableX: 23.45
theOtherVariable: 98
```

This is a simple tip, but I've seen it help people so many times.

When I'm coding, I use some weird names to spot them quickly in the logs, to be able to tell them from serious logs right away: 

```
console.log('myVariableX the UnicornFOO:', myVariableX) 
```
Now I can quickly spot UnicornFOO or search for it in the logs. 

I hope this helps you with debugging! 
 
---- 
Photo @sigmund, unsplash
Understanding Docker: part 25 – Dockerfile: CMD & ENTRYPOINT instructions
Tags: docker, devops, beginners, cloud
Published: 2021-01-04 07:24:58

---
title: Understanding Docker: part 25 – Dockerfile: CMD & ENTRYPOINT instructions
published: true
description: Serie of sketchnotes about Docker. Explaining in a visual way Docker principles.
tags: Docker, DevOps, beginners, Cloud
series: Understanding Docker in sketchnotes
cover_image: https://dev-to-uploads.s3.amazonaws.com/i/bi7a7qll7w91wpx43sr9.jpeg
---

Understanding Docker can be difficult or time-consuming. In order to spread knowledge about Cloud technologies I started to create sketchnotes about Docker. I think it could be a good way, more visual, to explain Docker (and other technologies like Kubernetes and Istio).

We continue the series of Docker sketchnotes with an explanation about CMD & ENTRYPOINT instructions in Dockerfile.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/bi7a7qll7w91wpx43sr9.jpeg)

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/x5qgz9im7wbc4xkw09od.jpeg)

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/6wlt79s90f9sn6zmvx68.jpeg)

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/8us7sa6c2mgefjlx13rq.jpeg)

As usual, if you like theses sketchnotes, you can follow me, and tell me what do you think. I will publish others sketchs shortly :-).

If you are interested, I published all the sketchnotes on Docker (and new ones!) to make a "book" of 93 pages: ["Understanding Docker in a visual way"](https://gumroad.com/aurelievache#YTLzM).
8 Ways Web Servers Can Tell Your Web Crawler Apart From Humans
Published: 2021-01-04 07:21:32

While it is fun to wrangle with machine learning solutions that can solve CAPTCHAs, If you do a lot of things well especially, proxy rotation from a large enough pool of proxies, you will rarely face this problem. This is because, unless they are behind a login screen (and a paywall), it doesn't make sense to interrupt users with CAPTCHAs randomly as it amounts to bad user experience. So mostly CAPTCHAs are made to appear after the webserver has some way of counting down the number of times a particular user has accessed the service.

In our own experience with hundreds of clients at Proxies API, we have found this to be true if you impersonate multiple humans in other areas than in solving CAPTCHAs.

Namely, these areas. This is largely how web servers can tell you are not human.

Your browser's signature (User-Agent-String) remains the same during multiple web scraping requests.
Your IP address remains the same, and so gets blocked.
You change your IP to a proxy but don't change your browser's identity (User-Agent-String)
You dont have enough proxies so gradually, all of them get blocked.
You are making too many requests per second.
You are too regular in your requests.
You are not sending back cookie data and other small clues.
You are unable to solve CAPTCHAs.
If you are looking for a professional and scalable to permanently solve most of the 8 "tells" I have listed above, you can have a look at Proxies API. We have a running offer of 1000 API fetches completely free :-)
Run Quarkus inside docker | Dockerizing a Quarkus Application
Tags: devops, docker, java, opensource
Published: 2021-01-04 07:21:01

{% youtube DAT0F87FeYs%}

In this article we are going to run Quarkus application inside Docker container.

The main focus of lab session is to compile the docker image and run the **Quarkus application** inside the docker.
Asynchronous Web Scraping with Python, aiohttp, and asynci
Published: 2021-01-04 07:17:12

One of the features of our Rotating Proxy Service Proxies API is the enormous concurrency it offers straight from the free plan itself. This is because we wanted the ability to scale our customer's web scrapers to be there from moment one. People do ask us what the best way to make concurrent requests on their side is. So we thought we would put together a getting started code that helps you understand and get started with async requests in Python.

Async is a better option than multi-threading because it's challenging to write thread-safe code.

So here is an example of fetching multiple URLs simultaneously using aiohttp module.

We will try and fetch all the URLs from this array.
First, we will initialize everything by loading the modules we need.
We need a function to handle individual fetches.
Notice how we use the start_time is stored in an array for each URL, and the time taken is calculated and printed.

The fetch_urls calls the ensure_future function to make sure the URLs finish fetching.
The fetch_async sets up the event loops and uses the run_until_complete to wait till all the URL fetches are completed to pass the control back so we can print the total time taken.
Putting it all together
And when you run it.
This will scale, but If you want to use this in production and want to scale to thousands of links, then you will find that you will get IP blocked quickly by many websites as well. In this scenario, using a rotating proxy service to rotate IPs is almost a must.

Otherwise, you tend to get IP blocked a lot by automatic location, usage, and bot detection algorithms.

Our rotating proxy server Proxies API provides a simple API that can solve all IP Blocking problems instantly.

With millions of high speed rotating proxies located all over the world
With our automatic IP rotation
With our automatic User-Agent-String rotation (which simulates requests from different, valid web browsers and web browser versions)
With our automatic CAPTCHA solving technology
Hundreds of our customers have successfully solved the headache of IP blocks with a simple API.

A simple API can access the whole thing like below in any programming language.

You dont even have to take the pain of loading Puppeteer as we render Javascript behind the scenes, and you can just get the data and parse it any language like Node, Puppeteer or PHP or using any framework like Scrapy or Nutch. In all these cases, you can just call the URL with render support like so.
Getting Started With Quarkus : Hello World 
Tags: devops, docker, java, opensource
Published: 2021-01-04 07:16:43

{% youtube 8aZdcw9OO6g%}

In this article we are going to see - 
1. What is Quarkus
2. How can we write our first **Hello World** with it.
3. Also we are going to see how to implement your micro-service.
How to add code highlighting and CodePen to your Dev.to posts.
Tags: devto
Published: 2021-01-04 07:13:00

This is very simple

{% codepen https://codepen.io/cassidoo/pen/MyaWzp %}

```javascript
const turorialFunction = (name) => {
  console.log(`Hello ${name}`)
}
```

 
#How to do it

Dev.tos posts are based on Markdown. Within Markdown we can use identation or so called Code Blocks to specify sections of code. The later ones are indicated using ```. Read more about this in this cheatsheet.

Using the three ` variant we can also specify a language for the code block. A lot of tooling build on top of Markdown utilized this characteristic to implement richer features. But the simplest of them is code highlighting. The above nicely colored code snippet is achieved by starting the code block with ```javascript.

The full example for the above would be:

![codepen](https://dev-to-uploads.s3.amazonaws.com/i/3e138nx497lwfy0ppgqy.PNG)
 
![Capture](https://dev-to-uploads.s3.amazonaws.com/i/otwviz5mmki6gsig9dtk.PNG)
Don't forget your --release flag when benchmarking
Tags: rust
Published: 2021-01-04 06:52:59

Saw this [very old post](https://github.com/amitkgupta/nearest_neighbour) comparing k-NN algorithm implemented in different languages, and for the love of my life I can't believe Rust runs the thing in over 1 minute.

So I took the code referred to in the post and ran it. Well it ran in over 40 seconds. I puzzled for an hour, even trying to implement the Go style code in Rust.

Then I realized I forgot the `--release` flag. I append it. It runs in not even a second. 

How I got distracted by this when I was on that old blog for Hindley-Milner is another question.
Conquering AWS Certification | AWS CCP | Day 1 | 
Tags: aws, webdev
Published: 2021-01-04 06:48:52

{% youtube 5ifVGRMnHt8 %}

In __2021__ I'm trying to upgrade my skills hence I'm planning to do certification on __AWS__ and __MongoDB__ in the Q1, later i will learn  __Flutter__ __NodeJS__ but let's not discuss my yearly goal as of now because i procastinated a lot last year and now i just want Deep Focus on small task(make sense?).

I will start with __AWS Cloud Practitioner Certification(AWS CCP)__ and __MongoDB Developer Associate__ then later i will prepare for __AWS Solution Architect Associate__.

my target is to finish these 3 certification in the first quarter.

I will keep sharing my journey and useful resources to all of you.

_PS: I'm not a pro in writing blogs, it's my first blog but i will improve myself over time and it will be worth your time._
Best Free Hosting Providers
Tags: webdev, help, beginners, hosting
Published: 2021-01-04 06:44:00

List of top free best-hosting providers.

1. <a href="https://byet.host/">ByteHost</a>
2. <a href="https://www.infinityfree.com">InfinityFree</a>
3. <a href="https://www.000webhost.com">000Webhost</a>
4. <a href="https://zyro.com/">Zyro</a>
5. <a href="https://x10hosting.com">X10hosting</a>
6. <a href="https://www.freehosting.com">Freehosting</a>
7. <a href="https://www.freehostia.com">Freehostia</a>
8. <a href="https://www.awardspace.com">Awardspace</a>
9. <a href="https://www.agilityhoster.com/free-web-hosting.html">Agilityhoster</a>
10. <a href="https://www.atspace.com/web-hosting/free-hosting/">AtSpace</a>
11. <a href="https://googiehost.com/index.html">Googiehost</a>
12. <a href="https://www.instafree.com">Instafree</a>
13. <a href="https://www.freewebhostingarea.com">Freewebhostingarea</a>
14. <a href="https://www.5gbfree.com">5gbfree</a>
15. <a href="https://www.dreamnix.com">Dreamnix</a>

Top static site hosting websites
1. <a href="https://www.netlify.com">Netlify</a>
2. <a href="https://pages.github.com">GitHub Pages</a>
3. <a href="https://vercel.com">Vercel</a>
4. <a href="https://firebase.google.com">Firebase</a>
5. <a href="https://about.gitlab.com/stages-devops-lifecycle/pages">GitLab Pages</a>
Laravel Framework: The Ultimate Guide 2021
Tags: beginners, laravel, webdev, tutorial
Published: 2021-01-07 07:50:31

---
title: Laravel Framework: The Ultimate Guide 2021
published: true
date: 2021-01-04 06:28:44 UTC
tags: beginners,laravel,webdev,tutorial
canonical_url: https://medium.com/code-story/laravel-framework-the-ultimate-guide-2021-ad78d50a4b39
---

[![](https://cdn-images-1.medium.com/max/1920/1*2RXV8qZv77JQkQ8bTvHLKw.png)](https://medium.com/code-story/laravel-framework-the-ultimate-guide-2021-ad78d50a4b39?source=rss-8b0955f01559------2)

This is the most comprehensive guide to the Laravel Framework online.

[Continue reading on Code Story »](https://medium.com/code-story/laravel-framework-the-ultimate-guide-2021-ad78d50a4b39?source=rss-8b0955f01559------2)
275 bytes BMI Calculator
Tags: html, javascript, css, codepen
Published: 2021-01-04 06:28:23

You don't always need a large frontend framework for interactive components. 

As an example, I've made a BMI Calculator, which is only 275 bytes, minified and gzipped.

I always wrap smaller, interactive components, in either a `<form>` or a `<fieldset>`-tag.
Depending on the component, I add a single `eventListener`, either `onchange` or `oninput`.

This is a "catch all" for any input within the `<form>` or `<fieldset>`. If I need to know the specific element that changed, it's in the `event.target`.

Let's dissect the calculator. The `<form>` has two `<input type="range">` (height, weight) and three `<output>`-tags (height info, weight info, bmi result).

Excerpt:
```html
<input type="range" name="h" min="150" max="230" step="0.5" value="180" />
<output name="ho"><output>
```

The un-minified JavaScript-code looks like this:

```js
function B() {
  const groups = [[0,18.49], [18.5,24.99], [25,29.99], [30,34.99], [35,39.99], [40,100]];
  const height = this.h.valueAsNumber;
  const weight = this.w.valueAsNumber;
  const bmi = parseFloat(weight / ((height / 100) ** 2)).toFixed(2);
  const index = groups.findIndex(arr => arr[0] <= bmi && bmi < arr[1]);
  let inches = (height*0.393700787).toFixed(0);
  this.ho.value = `${height} cm / ${Math.floor(inches / 12)}' ${inches %= 12}"`;
  this.wo.value = `${weight} kg / ${(weight*2.2046).toFixed(2)} lb`;
  this.g[index].checked = true;
  this.r.value = bmi;
}
```

`groups` is an array of BMI-ranges, corresponding to the six BMI-groups (underweight, normal weight etc.).

`height` and `weight` are references to the range-input values.

`bmi` is the formula for calculating a BMI using height and weight.

`index` finds the index of the BMI-group, in which range the current `bmi` is found. This value is later used to set the current BMI-group (a radio-button-group):

```js
this.g[index].checked = true;
```

An `<output>`-tag can either be set using `.innerText` or `.value`. I prefer the latter, and that's how the labels are set, as an example:

```js
this.r.value = bmi;
```

And the result:

{% codepen https://codepen.io/stoumann/pen/LYRdmVY default-tab=result %}

The code itself is 381 bytes, gzipped approx. 275 bytes. **However**, if your modules are so small, there's no benefit in gzipping them, as the "un-gzipping" will take longer than the benefit of the smaller file-size.

Thanks for reading, and happy coding!
Useful Bash/Terminal Commands
Tags: markdown, github, computerscience, git
Published: 2021-01-04 06:00:38

These are the basic commands for navigating directories in a Terminal or Git Bash window
### Moving in directories

#### Change Directory

`cd [path/to/desired/directory]`

#### Change to Home Directory

`cd ~`

#### Move to One Directory Up

`cd ..`


#### View Folders and Files in the Directory

`ls`

#### Show the current Directory

`pwd`

#### Autocomplete a File Name in the Current Directory
Press `tab` key once to autocomplete once you have typed a unique portion of a file name. 

### File Manipulations

#### Make New File

`touch [name of file to create]`

#### Make New Folder

`mkdir [name of directory to create]`

#### Delete file

`rm [name of file to remove]`

#### Delete folder

`rm -r [name of directory to remove]`

#### Copying File

`cp [filename1] [filename2]`

#### Move/Rename File

`mv [filename1] [filename2]`

### Mac Only

#### Open file or folder (Mac only)

`open [name of file]`

#### Open all files and folder in current directory (Mac only)

`open .`

### PC Only

#### Open file or folder (PC only)

`explorer [name of file]`

#### Open all files and folder in current directory (PC Only)

`explorer .`
How to run JS Code in VS Code
Tags: javascript, visualstudiocode, git, bash
Published: 2021-01-04 05:23:22

*Hey all!Hope you all are doing well.*

*Usually we run the javascript code by linking it with HTML file and viewing output in browser.*

### In this blog post,let us see how to run Javascript code in Visual Studio Code. 

1. At first you need to install NodeJS in your Windows/Macbook.
You can install it from here:
https://nodejs.org/en/

2.
  - Create a new folder and open it in VS Code
  - Write the javascript code and name it with extension .js
  - After completing the code save the changes that you made

3.Open the terminal in VS Code.

Now , move to the current directory in which you are there using following command.

![image1](https://dev-to-uploads.s3.amazonaws.com/i/gnfmlvx68fv0zzcculo3.png)

You have moved to the directory in which your JS code is present.

4.Type the following command in VS code terminal to view the output of your code.

![image2](https://dev-to-uploads.s3.amazonaws.com/i/wzgs3ythg0d0lo3f8ovj.png)

Yes!!! That's it. By following the above steps you can view your output without the need of HTML file.