teleren/devto huggingface dataset:
Do blue light glasses really work?

Tags: readingglasses, onlinestore
Published: 2020-10-29 08:14:16

What is blue light blocking glasses?
<a href="https://readersusa.com/">blue light glasses</a> block a portion of the high-energy blue light produced from electronic gadgets like cell phones, PCs and TVs. You know, the ones we gaze at throughout the day. 

Indeed, even your normal indoor light can emit blue light. The biggest maker of blue light, the sun, conveys monstrous measures of blue light. 

Would you be able to profit by blue light impeding glasses? How about we discover. 

What are blue light impeding glasses? 

When something produces light, various tones vibrate at various frequencies. The blue-violet light is called high energy noticeable (HEV) light. That is the part that most intently takes after the sun's possibly harming blue light. 

Normally, fake blue light is a lot more fragile than the sun's blue light. Yet, the normal American presently invests such a large amount of their energy inside before computerized screens that the lower pace of introduction begins to add up. 

It is obscure whether electronic blue light can legitimately mess eye up, however it might contribute. 

"The normal time on gadgets and before screens for grown-ups is pushing 11 hours out of each day, and accordingly, our eyes are under a ton of advanced light strain," said Dr. Sheri Rowen, an ophthalmologist and individual from the Eyesafe Vision Health Advisory Board. 

"The focal points are intended to help decrease the event of advanced eye strain and evade circadian mood cycle interruption, influencing rest and generally speaking prosperity," Rowen said. 

Blue light glasses block a level of this light with an extraordinary covering that mirrors a portion of the blue light away from your eyes. How high that rate is relies upon which glasses you purchase. 

Some blue light glasses have a yellow color, while others look clear. Normally, focal points that look more yellowed will in general channel more blue light than their more clear partners.


Buy Reading Glasses Online : <a href="https://readersusa.com/">Click Here </a>
Website Design Company | Website Designing & Website Development Company in Delhi | IT Nucleus
Published: 2020-10-29 07:54:37

IT NUCLEUS - A Website Development Company in India Offers Website design, Web Development, Graphic Design, Domain Registration, Web Hosting and Search Engine.

We provide eagerly helps businesses and individual clients all over the World to establish and maintain a professional Internet presence. That will effectively promote our clients products and services to their target audience. And professional website design will make your website stand out to your site visitors and accomplish the website goals you have created! Professional Website Designers Get A Free Quote.

https://www.itnucleus.com/
Top 5 Revenue Generating Mobile Applications In 2020
Tags: mobileappsdevelopmentservices, mobileappsdevelopment
Published: 2020-10-29 07:43:29

Mobile applications have become an inseparable part of our lives. From food to entertainment, health, education, finance, dating, shopping, and many more, people are using mobile applications for everything.
Why?
More than 70% of people own smartphones and they prefer to perform a particular task using mobile phones. According to the statistics, people don't like to use their computers or laptops to search for anything. Users take out phones from their pockets and search for things in just a matter of seconds. 

https://milliejackupdates.blogspot.com/2020/07/top-5-revenue-generating-mobile.html
A Gopher Client in Rust - 01 Notes on Gopher
Tags: gopher
Published: 2020-10-29 01:26:21

I'm going to implement a Gopher client in rust because it seems like a good project to try out. I'm going straight to the source for this which means that I'm going to implement the client based on my reading of the RFC. Which will be a first and I think quite fun. It's short RFC and the gopher protocol is very simple. I'm also going to use bare rust so I'll try to keep the number of dependencies down to 0.

Let's get started!

### Gopher

The RFC to read:
https://tools.ietf.org/html/rfc1436

- Protocol goes over TCP on port 70
- Clients send strings called 'selector' to the server
- The Server responds with text and terminating chracter is a period on a line by itself.
- Connection is automatically closed.

- Gopher is designed to appear like a filesystem
- Each line in a gopher listing 5 parts
    - Type
    - User visible name
    - Path
    - Domain name
    - Port
- User should only see the User Visible Name

- Only time the Client sends back more than one string is on a search, selector is sent along with a space delimited string of words to search for
- Server will respond with a regular listing but this may span multiple subnets and even the internet

Example of a Gopher listing:
0About internet GopherFStuff:About usFrawBits.micro.umn.eduF70

F is tab, so a gopher listing is a tab delimited string, with each string being on a new line.

TypeUser Visible NameFPathFDomain nameFPort

- Note Type doesn't have a tab delimiter.

Path is the selector string the client will send to the Domain Name on Port.

- User should only see the User Visible Name.

- If there is more tabs than this, ignore the rest.

- Displaying the types is up to the client and the author's taste.

- There can be root level Gopher servers that hold listings pointing to other Gopher servers, this should be load balanced.

- Recommended to have an About document with contact information as well as what the server holds on each Gopher server in the top level.

- The base types are 0 for files, 1 for directories and 7 for search.

- Client can save the paths the User navigates to to form a stack

- Client can cache stuff to skip network calls

- Types that are not known can be marked as unknown or ignored, up to the client

- New features to Gopher are only done via the types field, any further changes to Gopher will be server changes.

This is the distilled down notes of the RFC and should be enough to get started. The design I'll go for is that of the Linux shell and I'll treat Gopher as a filesystem as the RFC mentioned. 

Something I've learned as I built the client and browsed around is the i type, it is sort of an unofficial addon to the gopher protocol such that you can attach links and text all in one document. 

A very hacky but smart solution to a problem and I'm curious who came up with it :)
How to send a sms in Node.js
Tags: javascript, node, sms, twilio
Published: 2020-10-29 06:01:19


Hey Everyone! So we are going to take a quickstart to send a sms using node.js and twilio.This tutorial is easy because using twilio api we can send sms.Let's start.

#Step1:
First create free account on twilio.After that you will be redirect on https://www.twilio.com/console. On dashboard screen you will get a number which is use to send sms.There is two most important key available named as ACCOUNT SID and AUTH TOKEN.
This keys we used in code.

#Step2:
Now create new folder named as what you want and open terminal in that directory and write a command.

>npm init

Hit the enter to given questions.Now install the packages that we need.

> npm install twilio

Now create a new file named index.js and write lines of code.

```javascript
const accountSid = 'your-account-sid-twilio';
const authToken = 'your-authToken-twilio';
const client = require('twilio')(accountSid, authToken);

client.messages
  .create({
     body: 'Hello from node js',
     from: 'number-twilio',
     to: 'verified-number-twilio'
   })
  .then(message => console.log(message.sid))
  .catch(err => console.log(err));

```

>**NOTE**: **accountsid,authtoken and number-twilio are available on recently created twilio account.SMS will send to only verified number on twilio.if you want to add new number then you can add on dashboard right side**

Now run the file using command
>node index.js

**AND DONE**
I hope you liked the article!
Thank You!
Using gnu parallel to save time
Tags: linux, parallel, git, github
Published: 2020-10-29 05:52:36

As a developer I'm constantly reading code, specially from github.

Often I choose to clone repos from some user or organization and I've been using [parallel](https://www.gnu.org/software/parallel/) to save me some time  cloning and updating code.

## List repos

- [github-print-organization-repos.sh](https://github.com/joaovitor/parallel_commands/blob/master/bin/github-print-organization-repos.sh)
- [github-print-user-repos.sh](https://github.com/joaovitor/parallel_commands/blob/master/bin/github-print-organization-repos.sh)

## Clone missing repos

- [clone-missing.sh](https://github.com/joaovitor/parallel_commands/blob/master/bin/clone-missing.sh)

## Update repos from a directory **in parallel**

- [update-repos.sh](https://github.com/joaovitor/parallel_commands/blob/master/bin/update-repos.sh)

-----

There are more details in [parallel_commands readme](https://github.com/joaovitor/parallel_commands).

-----

The workflows / scripts defined below assumes that you already have a GITHUB_TOKEN environment variable capable of listing github repositories and that you have the [parallel_commands/bin](https://github.com/joaovitor/parallel_commands/bin) in your PATH.

-----

`update-repos.sh` is the one that I most use daily.

It does a `git pull --rebase` and `git fetch --prune` in all repositories inside a directory in **parallel**. This can save you and your team **lots of time**.

-----

## Offline studing

[PacktPublishing](https://github.com/PacktPublishing) and [oreillymedia](https://github.com/oreillymedia) have lots of quality repos to be used in studies.

Imagine that you want to study kubernetes and clone all repositories from PacktPublishing that contains kubernetes in the name.

Filtering [kubernetes from PacktPublishing](https://github.com/PacktPublishing?q=kubernetes&type=&language=) shows 63 repositories. Cloning 63 repositories by hand would be at least **slow**.

Here is an nicer way of doing this:

1- Create a list of repos from PacktPublishing

You can use the **static file** in [this gist](https://gist.github.com/joaovitor/e1658abc0946ec9e5528c533f2f502a8).

```shell
mkdir -p ~/github-orgs/PacktPublishing
cd ~/github-orgs/PacktPublishing
curl -s -L -o PacktPublishing.txt https://gist.githubusercontent.com/joaovitor/e1658abc0946ec9e5528c533f2f502a8/raw/88df9a43c2f9253d686b4ca6eb45bf50c047678b/PacktPublishing.txt
```

Or get it with the `github-print-organization-repos.sh`.

This one take a while PacktPublishing has more than 6000 repositories. `github-print-organization-repos.sh` makes around 600 github api calls to generate the file with the list of repos.

```shell
mkdir -p ~/github-orgs/PacktPublishing
cd ~/github-orgs/PacktPublishing
gh_owner=$(basename $(pwd)); github-print-organization-repos.sh ${gh_owner} ${gh_owner}.txt
```

2- Clone the missing repos that match kubernetes

```shell
cd ~/github-orgs/PacktPublishing
gh_owner=$(basename $(pwd)); grep -Ei kubernetes ${gh_owner}.txt | parallel  -j 25 'clone-missing.sh {}; echo job {#} completed {};'
```

3- Study offline
Menggunakan Purge CSS
Published: 2020-10-27 14:55:49

---
title: Menggunakan Purge CSS
published: true
description: 
tags: 
//cover_image: https://direct_url_to_image.jpg
---

Install:

```bash
npm i -D purgecss
```

Di `package.json`:

```json
"scripts": {
	"purgecss": "purgecss --css public/dist/bootstrap.min.css --content src/**/*.svelte --output public/dist2",
	"build": "routify -b --dynamic-imports && rollup -c && npm run purgecss && node script/salin.js && node script/pakaiPurge.js",
},
```

Buat file `public/dist2/.hello`

Di `.gitignore`:

```javascript
/public/dist2/bootstrap.min.css
```

Tambahkan di `dist/global.css`:

```css
body{margin:0;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";font-size:1rem;font-weight:400;line-height:1.5;color:#212529;text-align:left;background-color:#fff}
```

Isi dari `script/pakaiPurge.js`:

```javascript
fs = require('fs')
namaFile = 'hasil/index.html'
fs.readFile(namaFile, 'utf8', (_, x) => {
	x = x.replace('/dist/bootstrap.min.css', '/dist2/bootstrap.min.css')
	fs.writeFile(namaFile, x, 'utf8', () => {})
})
```

Hasil: <https://svelte-brown.vercel.app/>

Catatan: Dia kalau di Svelte kita pakai dynamic class (nggak ditulis langsung di htmlnya, nama classnya), purgecss nggak bisa deteksi. Solusinya pakai whitelist di option purgecss (ada di Google tutorialnya)
Light and dark mode image in HTML
Tags: html
Published: 2020-10-29 04:47:27

Did you know you can change images bases on the user preferred Color-scheme?

This nifty piece of code could already be used in [`CSS`](https://daily-dev-tips.com/posts/theme-switching-favicon-%F0%9F%99%8A/), but did you know it works directly in `HTML`?

We can detect if the user prefers a dark or light color schema and show a different image to them based on that!

It will look like this:

![HTML Prefer color scheme](https://cdn.hashnode.com/res/hashnode/image/upload/v1603260556327/l6fdQ5GXw.gif)

## HTML Structure

```html
<picture>
  <source srcset="dark-mode.png" media="(prefers-color-scheme: dark)">
  <img src="light-image.png">
</picture>
```

That's is it!

By default, it will show the light image, but it will show the dark image if the person prefers the dark scheme.

Feel free to have a play with this on Codepen.

{% codepen https://codepen.io/rebelchris/pen/bGewmom %}

## Browser Support

The support for prefers-color-scheme is getting better, but still not a reliable option to choose.

![CSS prefers-color-scheme support](https://caniuse.bitsofco.de/image/prefers-color-scheme.png)

### Thank you for reading, and let's connect!

Thank you for reading my blog. Feel free to subscribe to my email newsletter and connect on [Facebook](https://www.facebook.com/DailyDevTipsBlog) or [Twitter](https://twitter.com/DailyDevTips1)
Asynchronous Javascript
Tags: javascript
Published: 2020-10-29 04:17:45

I have some trivial doubts regarding Asynchronous functions.

1) When await keyword is encountered in async function, what does js exactly do ?
does it skip the whole function and goes to next next instruction outside the function or will it try to execute rest of the code in async ( i personally think the first one as whatever inside a async func is supposed to be executed after the asynchronous instruction)

2) Javascript has single thread and event based model. so if it encounters asynchronous code, i have read that it works in the background executing other instruction. what does executing in the background mean (if only it has single thread)?

3) If in a code every instruction is depends on result of previous async function ,doesn’t executing in both synchronously and asynchronously becomes same ?

Kindly answer these question whenever you have time.

Thanks in advance.
Hello
Tags: firstpost, observant
Published: 2020-10-29 03:56:17

Beep boop swoopity swoop...Just kidding I'm just an observant reader and mostly to watch some tech news. I'm not much of a developer (I can't make a batch file to save my life). I came to dev through Medium. Might be the first and possibly the last post. If you want me to write I could write more.
Thanks, guys
New Opensource Project Hosted on Github
Tags: javascript, opensource, devops
Published: 2020-10-29 03:41:48

Created a new opensource project if anybody would be interested in helping building it      https://www.art4coding.icu The project files can be found here:      
https://github.com/MistaKistHur/Art4Coding-Resources it's to build a website that would bring Artist and coders together to collaborate on various different projects We Have Two seperate groups to Use for communication and collaboration: https://www.facebook.com/groups/art4coding.icu    
https://www.deviantart.com/coding-artists
Hye there Start Data structure and algorithms learning here #1 Introduction
Tags: python, datascience, machinelearning
Published: 2020-10-29 03:31:09

This is the introduction to the data strcuture and algorithm series in python (in hindi) 
The link for Playlist : - 
https://www.youtube.com/watch?v=zO0WiYaIUtY&list=PL13aQMQVPecA33n8w9S-cwD9geQsY8JhU

Data Structure is about organising and managing data effectively such that we can perform specific operation efficiently, while Algorithm is a step-by-step procedure to be followed to reach the desired output.
Video Series: Sample IonSlides App Using Vue 3, In Ionic Framework
Tags: ionic, javascript, tutorial, vue
Published: 2020-10-29 03:13:42

>**Building apps using the new [Ionic Framework Web Components for Vue 3](https://ionicframework.com/docs/vue/quickstart).**

###Creating Slides with VueJS and Ionic Framework - Accessing the Full SwiperJS API

This is a basic introduction on how to utilize [IonSlides](https://ionicframework.com/docs/api/slides) in your vuejs application and how to get deep access to the underlying API from [SwiperJS](https://swiperjs.com/) that is what's driving IonSlides.

{% youtube -Qm-tG4Kt9s %}

###More Slides Using Ionic Framework with VueJS, SwiperJS and Tiny-Emitter Creating A Custom Event-Bus

We are combining two questions I saw this week, that I thought would make for a great video
1) How to emit events, create an event-bus in vue3
2) How to have parent component sent events to child component in vuejs.
3) [See Tiny-Emitter](https://github.com/scottcorgan/tiny-emitter), This approach was recommended in the Vue3JS Documentation regarding [Events API Migration](https://v3.vuejs.org/guide/migration/events-api.html#events-api)

Taking the Slides Demo from the earlier video and create a way for the IonSlides Component to listen for an event to tell it to change what slide it is on... This decouples the slide component from being tightly integrated with its parent in many ways.

{% youtube mCkrZYIbH10 %}

💥 BONUS SAMPLE CODE 💥
The library I used in [tiny-emitter](https://github.com/scottcorgan/tiny-emitter), the link is below, See a simple eventbus built using composition API here [CodeSandbox Project](https://codesandbox.io/s/quirky-minsky-hw0c2?file=/src/views/Tab1.vue)

### More VueJS & Ionic Videos
[![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/xw2w8i9ccngje6h77m8s.png)](https://www.youtube.com/channel/UCMCcqbJpyL3LAv3PJeYz2bg)
Elixir - csv import
Tags: elixir
Published: 2020-10-29 03:08:08

See Files on Github
[country-codes.csv](https://github.com/ideaMarcos/portishead/blob/main/priv/repo/country-codes.csv)
[create_country_table.exs](https://github.com/ideaMarcos/portishead/blob/main/priv/repo/migrations/20200113205300_create_country_table.exs)

This post expands on [this article from 'Experimenting with Code'](https://experimentingwithcode.com/using-the-postgres-copy-command-in-ecto-migrations/) to only import a subset of csv columns into Postgres using Ecto.

In this case, we are only concerned with the `code` and `name` columns from `country-codes.csv`. This example uses [File.stream()](https://hexdocs.pm/elixir/File.html#stream!/3) and [CSV.decode!()](https://hexdocs.pm/csv/CSV.html#decode!/2) to get just the two columns and pass it to the [COPY](https://www.postgresql.org/docs/current/sql-copy.html) command.

```elixir
file_path
|> File.stream!()
|> CSV.decode!(headers: true)
|> Stream.map(fn row ->
  [
    row["code"],
    row["name"]
  ]
end)
|> CSV.encode()
|> Enum.into(stream)
```
neovim as IDE
Tags: neovim, vim, vimplug
Published: 2020-10-29 03:01:42

# Install [neovim](https://neovim.io) (macos 😉)

```
brew install neovim
```

Others: https://github.com/neovim/neovim/wiki/Installing-Neovim

# Install plugin manager ([vim-plug](https://github.com/junegunn/vim-plug))

vim-plug is one of the simple plugin manager

```
sh -c 'curl -fLo "${XDG_DATA_HOME:-$HOME/.local/share}"/nvim/site/autoload/plug.vim --create-dirs \
       https://raw.githubusercontent.com/junegunn/vim-plug/master/plug.vim'
```

# Useful (n)vim plugins

`Plug 'gruvbox-community/gruvbox'` - Awesome theme 😉
`Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }` - Fuzzy finder, find almost anything
`Plug 'junegunn/fzf.vim'`
`Plug 'wincent/ferret'` - Powerful multi-file search
`Plug 'tpope/vim-commentary'` - comment out lines
`Plug 'tpope/vim-surround'` - surroundings
`Plug 'editorconfig/editorconfig-vim'` - maintain consistent coding styles for multiple projects
`Plug 'neoclide/coc.nvim', {'branch': 'release'}` - Intellisense engine for neovim 🤩
`Plug 'mattn/emmet-vim'` - emmet for vim
`Plug 'pechorin/any-jump.vim'` - Jump to definition or references
`Plug 'sheerun/vim-polyglot'` - collection of language pack, you can install individual language pack as you need

# Useful coc plugins

Install
```
:CocInstall <package-name>
```

`coc-explorer` - file explorer
`coc-marketplace` - coc plugins
`coc-smartf` - easily jump to any character
`coc-prettier` - formatter

# Useful bash utilities

1. [Lazygit](https://github.com/jesseduffield/lazygit) - terminal ui for git commands
2. [Lazydocker](https://github.com/jesseduffield/lazydocker) - terminal ui for docker
3. [broot](https://dystroy.org/broot) - new way to navigate directory tree
4. [tmux](https://github.com/tmux/tmux/wiki) - terminal multiplexer, [Easy Guide](https://www.hamvocke.com/blog/a-quick-and-easy-guide-to-tmux)

# Useful terminals

1. [Alacritty](https://github.com/alacritty/alacritty) -  GPU-accelerated terminal emulator, `brew cask install alacritty`
2. [iterm2](https://www.iterm2.com) - terminal emulator for macos
How to Store a Long, Multi-line Private Key in an Environment Variable
Tags: nextjs, googlecloud, azure, firebase
Published: 2020-10-29 02:48:57

Most of the time you store simple, straight forward private keys for your deployments, but sometimes your project requires some complex ones like this one below.

```
-----BEGIN PRIVATE KEY-----
MIIEvQIBADANBgkqhkiG9w0BAQEFAASCBKcwggSjAgEAAoIBAQCt95m8QfrcIR+o
0a7S1hTtcbt7NhEJLiVELktu1XsFSitazhwvrRuVGn1c+cqgQbmAp7x/xoaYcLfY
tAaKR9v1xNEIBEwA/h1k+TFl7xJqH6Q07LBVYR0kVWiXgUHo6XWhlJEy4PCC5Yqo
eV2ZsA4Jjsh8c0cWTEFX9cCCT8cRIOfMeR/TcAeF/bPEOnmrbJJLV+5ivJUCHpio
[...]
tQeRV0IfFdnW8V3y6XI+xFYBOkx7D4BGFF8fUNr0iYMCWvICu2cJlWqi6Qmlk+LJ
br9Sl3Y2c1bXQbsW2ZKQJTANKBxeY1i9Au1pdCUCgYEAzbqB5omxKXcXx/0ZI/ao
cIJ9hQ6S18JIniG7DFyyUzqHansnqD1Qqxefl1fFLcuWktUivfbr7v5FoWUjwKLQ
JOJOVI3DZCsOumPrpEpjRa4cCQEjNPqYHL4voIR5IHRr+4iKSVrXUcmhdyqxjonG
11Avbqh479wA4VYksAF9AM4=
-----END PRIVATE KEY-----
```

When your project is ready to launch, but you're getting stuck in a few minor, silly errors like `Failed to parse private key: Error: Invalid PEM formatted message`, you know that the problem is how the environment variable is stored, but have tried a lot of things to try to get it to work.

Well... hoping to save someone some time, I've ran across this pretty elegant solution in GitHub.

Store your multi-line Private Key like this:
```
FIREBASE_PRIVATE_KEY='{"privateKey":"-----BEGIN PRIVATE KEY-----\nMIIEvQIBADANBgkqhkiG9w0BAQE...-----END PRIVATE KEY-----"}'
```

and use it in the code as following:
```
const { privateKey } = JSON.parse(process.env.FIREBASE_PRIVATE_KEY)
```

Peace!
Want to gateway all from nginx, Here it is
Tags: hacktoberfest
Published: 2020-10-29 02:39:01

Yes, Nginx can be a perfect gateway for http requests. Then what about SSH2, TNS(Oracle), TDS(SQL Server),...? Oh you got stream module. It's not naturally designed for human programmer and it's far from enough. Here is a library trying to solve these problems and it's easy to use.
github:https://github.com/yizhu2000/suproxy/
maillist:suproxy@googlegroups.com

### [Intro Heading]
I'm joey, a programmer from China, this is my first opensource project. I'm not really familiar with all those things, hope Dev and hacktoberfest can help me find some guy who share the same interests with me.
### Background