teleren/devto huggingface dataset:
[Prize Discussion] Plato Talk #3
Tags: beginners, discuss, devops, privacy
Published: 2022-01-11 13:45:17

## PLATO TALK #3


#### TOPIC：Privacy-Preserving Computation Application Scenario Sharing
“Share what you think is a viable implementation scenario and solution based on Privacy-Preserving Computation technology”

REWARD: **4000 LAT**

Topic Deadline: **2022/1/13 12:00 UTC**

Online Events-Discord（plato-talk）: **https://discord.gg/CGz3cSfn9J**


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/k2k7wtgjlzpx42h1wm1s.png)


Event details：

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/h1n6owdj57al7bbjemog.png)
Greetings everybody
Tags: react
Published: 2022-01-11 13:39:51


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0rasj90kim2zemivxsf9.jpg)

Hi,

I am new here. I am studying React.js, PHP, Vue, etc.
Looking for a remote job and building my business.

Regards,

Veronica Chiaravalli
React Basic 
Published: 2021-12-22 17:50:01

What is JSX?
JSX is a shorthand for JavaScript XML. This is a type of file used by React which utilizes the expressiveness of JavaScript along with HTML-like template syntax. This makes the HTML file really easy to understand. 
An example of JSX:

```
render(){
    return(        
          
<div>
             
<h1> Hello World from Asif!!</h1>
 
         </div>
 
    );
}
```
What do you understand by Virtual DOM? Explain its working.

A virtual DOM is a lightweight JavaScript object which originally is just the copy of the real DOM. It is a node tree that lists the elements, their attributes and content as Objects and their properties. React’s render function creates a node tree out of the React components. It then updates this tree in response to the mutations in the data model which is caused by various actions done by the user.This Virtual DOM works in three simple steps.
1.	Whenever any underlying data changes, the entire UI is re-rendered in Virtual DOM representation
 
2.	Then the difference between the previous DOM representation and the new one is calculated.
 
3.	Once the calculations are done, the real DOM will be updated with only the things that have actually changed.
 
Explain the purpose of render() in React.
It is mandatory for each React component to have a render() function. Render function is used to return the HTML which want to display in a component. If need to rendered more than one HTML element, need to grouped together inside single enclosing tag (parent tag) such as <div>, <form>, <group> etc. This function returns the same result each time it is invoked.

Example: If need to display a heading, can do this as below.



```
import React from 'react'

class App extends React.Component {
render (){
return (
<h1>Hello World</h1>
)
}
}
export default App
```
Points to Note:
	Each render() function contains a return statement.
	The return statement can have only one parent HTML tag.
Lifecycle Methods Order In Mounting:
Mounting is the first phases of React component lifecycle. when an instance of a component is being created and inserted into the DOM, the following methods are called- constructor(), render(), componentDidMount().

Reconciliation:
Reconciliation is When a component's props or state change, React decides whether an actual DOM update is necessary by comparing the newly returned element with the previously rendered one. When they are not equal, React will update the DOM. This process is called reconciliation.
Higher Order Component:
A Higher Order Component is the advanced technique in React for reusing a component logic. Higher order component takes a component and returns a new component. Simply, a higher order component transforms a component into another component. The proper example of higher order components are- redux’s connect and relay’s createContainer.
Uncomfortable with your theme? Just make one
Tags: beginners, productivity, vscode
Published: 2022-01-11 13:09:00

Can't find the right theme? or maybe you found one but suddenly found out there's something wrong about the theme and make you feel uncomfortable. It might even affect your productivity

![Uncomfortable](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/b62m4s28zex1g0krhqvo.gif)

Well just make one. Yeah it's easier than I thought.

I'm not gonna give you a tutorial that **already** has been made, an information about how easy is it is just enough so [here is the link](https://code.visualstudio.com/api/working-with-extensions/publishing-extension)

And I just made one myself combining ayu's color scheme and my own prefered colors. [Here check it out](https://marketplace.visualstudio.com/items?itemName=HeavenAldrico.aldrico-s)

![Sample](https://github.com/ldriko/aldrico-s/blob/main/images/sample.png?raw=true)

Thanks for reading my first article. Please share your thoughts or share your own theme in the comment below thanks!
How do you manage Docker secrets?
Tags: docker, api, python, discuss
Published: 2022-01-11 12:53:00

There seem to be a lot of posts about how to use and deploy docker but not much about how to connect many of the linking parts? 

I.e how to pull environment variables from docker secrets to use inside a container. 

Also if creating a containerised API, for deployment on a server, how do you build the API locally to interact with a db elsewhere that you only have access to remotely?
Documentação de Regras de Negócio
Published: 2022-01-11 12:12:02

Regras de Negócio são declarações sobre a forma da empresa fazer negócio. Elas refletem políticas do negócio. As regras podem assumir muitas formas, de simples decisões booleanas, cálculos a decisões que envolvem regras de lógica mais complexas.

As Regras de Negócio(RN) Definem Como, Quando, Quem,  Onde e Por Quê as operações do software devem ser realizadas. Dois ou mais Sofwares podem ter funcionalidades em comum mas implementadas de acordo as regras de Negócio de cada empresa.

As Regras de Negócio estão caminham juntas aos Requisitos Funcionais(RF). Embora os Requisitos apenas definem a operação que será implementado.

Quando não se identifica um RF provoca um débito técnico, que poderá ser solucionado com facilidade, ao passo que uma RN mal especificada pode gerar mais problemas. Uma RN mal implementada resulta em grandes perdas, principalmente quando identificados na fase de produção.


## Representação das RN
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/z9k3rd65k1bn9jl40nqn.jpg)


**Exemplo**: Neste exemplo vamos documentar as Regras de Negócio, de forma simples, numa tabela.
**Processo**: Avaliação de Estudantes.
**Instituição**: Universidade XPTO.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4b3po9mxjgsgtst61w6f.jpg)


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4gxqqy5rhjdrw4ogi6s8.jpg)
Hosting a discord bot on Railway
Tags: discord, serverless, javascript
Published: 2022-01-11 12:10:20

Now that we have our super cool [discord bot that can respond to our slash commands](https://daily-dev-tips.com/posts/show-and-hide-a-header-based-on-scroll-direction/), we need a way to host it.

Until now, we just used it by starting a local node instance, but this means the process stops every time we close our computer.

Because I'm Dutch, I went the cheapskate way and found this fantastic hosting service called [Railway](https://railway.app/). Their free tier ($5 a month) is enough to host a simple discord bot.

In this article, I'll guide you through the process of setting this up.

## Hosting a discord bot on Railway

Make sure you log in with your favorite social provider.
Then we can click the `New Project` button to add a new project.

![New project on Railway app](https://cdn.hashnode.com/res/hashnode/image/upload/v1641011337459/aj2I65Ezc.png)

They then provide a couple of cool options we can choose from (including databases).

We will choose `Deploy from repo` from the options.

![Deploy from repo](https://cdn.hashnode.com/res/hashnode/image/upload/v1641011423144/yg6n60C8E.png)

Select the git project from the select field. Once this is done, click the `Add Variables` button and add the variables you used.

![Add variables to Railway app](https://cdn.hashnode.com/res/hashnode/image/upload/v1641014541624/VdFcsuWyT.png)

In the case of the slash command bot, you will need the following two:

```text
APP_ID={APPLICATION_ID}
TOKEN={YOUR_BOT_TOKEN}
```

Once you've added them click the create button, it will take a minute to set up, and you should see the logs for what's going on.

And once this is done, your bot is already up and running!

Yes, it can be that easy 🤯.

Big shoutout to the Railway app for making this possible and so simple.

### 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)
How to use 000webhost as your web hosting
Tags: tutorial, html, css, javascript
Published: 2022-01-11 12:07:24

Ok guys so i already made a post about how to convert your website into exe file. But it need a links to the website. But how about if you didn't have any server to hosting or you didn't have any website. This post is for you because today I'm gonna tell you how to hosting a website for free. The website is always online and it's 100% Free.
WOW 😲...

**Hosting A Free Website**

I recommend you to use 000webhost.com because it's very simple and easy to create website there.

1. Create an account using google or anything else

2. After that there is like a welcome page with 2 buttons, just click on the "it's not my first rodeo, take me to the panel"

3. And then name your project

4. After you creating your project there will be a page with a text "Choose your weapon of mass creation"

If you using HTML to create website click on the third button by clicking the select button with the description "Upload your site"

5. After that you are on the panel and click "Create New Site"

And insert the website name and password and goto > Tools > File Manager > And create or upload your html file

Your website link can be found in the panel that have Create a new site button.


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pgstb97egq754ywoaj1b.jpg)

Thank you guys if you already watch this article until the end, if you have any problem feel free to ask in the comment section i will answer it as fast as i can.
Convert your website into EXE file using Node.JS/NPM/Electron
Tags: node, electron, tutorial, npm
Published: 2022-01-11 12:06:58

Cover designed by KindPng.com

Hey guys 😁, today I'm gonna be showing you how to convert your website link into exe file

1. Download node.js
2. When you downloading make sure you click the button "Add to PATH", and then you ready to install.
3. Open cmd and type "npm install -g nativefier"
4. Wait until the installation is finished.
5. After that type like this "nativefier --name 'Your App Name' 'myapp.com'"
6. Wait until the converting is finish and goto C:/Windows/System32/And search folder with the name "yourappname-win32"

If you have any problem feel free to ask, im gonna answer as fast as i can

Link to hosting a free website: https://dev.to/supremewyn/free-web-hosting-100-free-4h59

Check out another articles from me:
https://dev.to/supremewyn/html-code-to-create-website-using-html-css-2p3l

https://dev.to/supremewyn/html-for-beginner-part-1-9me
Ignoring HTTP_PROXY environment vars in Go
Tags: go, todayisearched, programming
Published: 2022-01-11 12:01:07

Standard HTTP library in Go reads the environment variables `HTTP_PROXY`, `HTTPS_PROXY`, and `NO_PROXY`. But in some situations, those variables are ignored. On the other hand, the developer may want to disable the reading of those variables.

---

> 🇨🇿 V češtině si lze článek přečíst na [kutac.cz](https://www.kutac.cz/co-na-srdci-to-na-blogu/go-a-ignorovani-http-proxy) 

A proxy might be useful to go over the firewall of a company network when access to some sites is blocked. But a proxy is often used to debug and inspect communication during development. For example tools like [HTTP Toolkit](https://httptoolkit.tech/) creates a local proxy server.

Every program in Go using `net/http` will read `HTTP(S)_PROXY` and `NO_PROXY` variables and acts accordingly. But what if the developer wants to be sure, users cannot use proxy at all? The code below is an example for explaining further issues.

```go
func main() {
	fmt.Println(os.Getenv("HTTP_PROXY"))
	client := &http.Client{}
	resp, err := client.Get("http://localhost:8090/vm/1")
	if err != nil {
		log.Fatal(err)
	}
	body, err := ioutil.ReadAll(resp.Body)
	if err != nil {
		log.Fatal(err)
	}
	fmt.Println(string(body))
}
```

## I set HTTP_PROXY and it is ignored

In the code above the content of `HTTP_PROXY` is printed out and then called `GET` request. But even if the value is set correctly, it is ignored. The main reason is the request is made to **localhost** which is ignored as well as **127.x.x.x**. Luckily it is easy to go around this.

It is enough to set custom domain in `/etc/hosts` on Linux or `C:\Windows\System32\drivers\etc\hosts` on Windows by adding `127.0.0.1 localserver.loc` and then change the code above.

```go
resp, err := client.Get("http://localserver.loc:8090/vm/1")
```

This is documented behavior, but quite deeply. You can find it in source [opensource.google/x/net/http/httpproxy/proxy.go line 118](https://cs.opensource.google/go/x/net/+/internal-branch.go1.17-vendor:http/httpproxy/proxy.go;l=118) and on [line 181](https://cs.opensource.google/go/x/net/+/internal-branch.go1.17-vendor:http/httpproxy/proxy.go;l=181) is exact if which is responsible for that.

## How to disable reading PROXY environment variables

You can use variable `NO_PROXY` to set which URLs will never go through a proxy. You can specify all with `NO_PROXY=*` or list URLs delimited by comma. But what to do if you as a developer wants to ignore all those variables? Then the own `Transport` of HTTP Client must be set. 

```go
transport := http.DefaultTransport
transport.(*http.Transport).Proxy = nil
client := &http.Client{
	Transport: transport,
}
```
Mistakes in my First Flask web App
Tags: webdev, beginners, programming, css
Published: 2022-01-11 11:59:08

## **Getting Started**

I built this app as my **Portfolio Project** for ALX.

**Mistake 1** 
The minimum requirement was to be in teams of 3. This obviously allowed us to have a backend developer, a frontend developer and then perhaps a member who is strong in either one, both or a UI/IX designer. 
**_I was on my own_**

**Mistake 2**
I knew that my CSS, and HTML were not the greatest so I spent 3 weeks watching videos on how to build responsive web apps on Pluralsight. 
_Result: I did not have enough time to finish my project_

**Mistake 3**
When I finally made peace with my poor UI design skills, I began to focus on the Flask app itself. 
I had 2 weeks left by this time. 
To catch up, I watched so many videos on Youtube before even applying any of the knowledge. Where I struggled, I struggled in silence, and did not seek help. 

**Mistake 4**
Now things got a bit technical. I used SQLite3 as my database and everything was running so smoothly. I only had one issue, everytime I made a mistake, I had to drop all tables and start again. 
(I did not use Migrate).

I also ran into an issue on the day of my presentation. I had finally managed to deploy my web app but then I did not take into account that SQLite is great during development but not for production. On Heroku, it makes your app slow and is a file based database hence becomes buggy with Heroku. 



**Lessons**

1. No developer is an island. Most of the times, being in a team gives you the opportunity to learn from others. At the same time, working alone also helps you realise your weaknesses so you know what you can and can not do. 

2. Flask is an easy to use Python Framework but more support exists for Django than Flask. 

3. SQLite is great if you are just playing around in your local machine and learning how to use and query databases. It is definitely not going to be as great when you have to deploy your app. 

4. Learn, build, test, debug, and repeat the cycle. When you think you know it all, learn even more. I realised that throughout the projects I have built so far, I am only excited by testing code. Watching a program break just expected is my favourite thing about being a developer. The frontend of any project does not excite me at all. 

5. Learn the basics before you learn the Frameworks. Bootstrap? Do you know CSS? Flask? How is your Python? 

Lastly, hop onto my web app and help me by finding different ways it can be broken. 
[](https://millicentmalinga.pythonanywhere.com/)
Zustand React Typescript Tutorial (vs Easy Peasy)
Tags: webdev, javascript, react, redux
Published: 2022-01-11 11:47:44

Hey guys,
I've been using easy peasy for years now as an alternative to REDUX and I love it!

I'd like to make a comparison of this library with zustand (another state management library based on hooks) that I have used recently and that is more popular.

I personally prefer easy peasy, in this video I explain why!

{% youtube dOJkaYE249I %}
how to check ip address in Linux
Published: 2022-01-11 11:29:10


An IP address is a unique address that identifies a device on the internet or a local private network. Every computer in the network requires its own unique IP address to get identified. There are two different IP addresses: private and public. 

A computer can be assigned private IPs or public IP or both.
Private IP is assigned to devices such as laptops, printers, phones for internal communication. If this machine needs to communicate outside the world then needs to use a router.

There are few commands available in Linux to find the IP address. The popular command is ip.
$ ip addr

- ip addr — Show information for all addresses
- ip addr show dev em1 — Display information only for device em1

There are few more commands which can display the private IP address of your system.

$ ifconfig

To use this command to find the IP address, just type “ifconfig -a” in the shell prompt.

This command will list all the network interfaces along with their details which include interface status, IP address, MTU size, etc.

If we are only interested in certain interfaces, eth0, etc. then: ifconfig eth0
reference:

[how to check ip address in Linux
](https://www.howtouselinux.com/post/check-ip-address-in-linux)
4 examples to check os version in linux
Published: 2022-01-11 11:43:40

| Command | Example |
|:----|:----|
| uname -a | $uname -a<br>Linux ip-10-0-0-224 5.4.0-1045-aws#47-Ubuntu <br>SMP Tue Apr 13 07:02:25 UTC2021 x86\_64 x86\_64 x86\_64 GNU/Linux |
| more /proc/version | $ more /proc/version<br>Linux version 5.4.0-1045-aws(buildd@lcy01-amd64-026)(gcc version 9.3.0(Ubuntu 9.3.0-17ubuntu1~20.04)) |
| more /etc/os-release | $ more /etc/os-release<br>NAME=”Ubuntu”VERSION=”20.04.2 LTS (Focal Fossa)”ID=ubuntuID\_LIKE=debianPRETTY\_NAME=”Ubuntu 20.04.2 LTS”VERSION\_ID=”20.04″ |
| lsb\_release -a | $lsb\_release -a<br>No LSB modules are available.Distributor ID: UbuntuDescription: Ubuntu 20.04.2 LTSRelease: 20.04Codename: focal |


[how to check os version in Linux](https://www.howtouselinux.com/post/4-ways-to-check-linux-version)
26 FFmpeg academic papers from Chinese masters and PhD technical talents
Published: 2022-01-11 11:38:43

26 FFmpeg academic papers from Chinese masters and PhD technical talents ：[https://github.com/0voice/ffmpeg_develop_doc#-%E8%AE%BA%E6%96%87](https://github.com/0voice/ffmpeg_develop_doc#-%E8%AE%BA%E6%96%87)
5 websites to create awesome favicons
Tags: javascript, favicon, webdev, programming
Published: 2022-01-11 13:37:50

---
title: 5 websites to create awesome favicons
published: true
date: 2022-01-11 11:30:00 UTC
tags: javascript, favicon, webdev, programming
canonical_url: 
---

1️⃣ Favicon.io

Generate a favicon from text, from an image, or from an emoji. Download in .ico and .png formats

https://favicon.io/


2️⃣ Favicomatic

Generate favicons of all the sizes and formats as well as the HTML code needed to support every possible browser or device

https://favicomatic.com/


3️⃣ Favicon Generator

Generate icons for all platforms (Windows, iOS, Android)

https://realfavicongenerator.net/


4️⃣ FontIcon

Generate favicons and images from Font Awesome icons

https://gauger.io/fonticon/


5️⃣ Icon Kitchen

Powerful and free all-in-one icon generator

https://icon.kitchen

### Thank you for reading

If you liked this post, subscribe to our newsletter to never miss out on our blogs, product launches and tech news.

[Subsribe to Visualway's newsletter](https://tinyletter.com/visualway)
Python Reverse Integer – LeetCode Solutions
Tags: leetcode, pythonsolutions, leetcodesolutions, reverseintegersolutions
Published: 2022-01-11 11:21:05

LeetCode has a Medium coding Problem in Its’ Algorithm Section in Python “Reverse Integer”. Today We are going to solve this problem

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/v55glrc4b8hb86gkq4vc.jpg)

Question
Given a signed 32-bit integer x, return x with its digits reversed. If reversing x causes the value to go outside the signed 32-bit integer range [-231, 231 - 1], then return 0.

Assume the environment does not allow you to store 64-bit integers (signed or unsigned).

Solution to the problem is here https://hecodesit.com/python-reverse-integer-leetcode-solutions/
Drinkizz E-Commerce Application
Tags: atlashackathon, mongodb, react, javascript
Published: 2022-01-11 11:18:43

### Overview of My Submission
Hello Guys We are making  an E-commerce web application using NodeJS and ExpressJs for Backend and MongoDB for database, also we are use ReactJS for frontend, This app is Good user interface, This is an Online Liquor ordering platform 


### Submission Category: 

E-Commerce Creation


### Link to Code
Backend : (https://github.com/issc-Swapnil/drinkizz-api.git)
Frontend : (https://github.com/issc-Swapnil/drinkizz.git)
Hosting : https://www.heroku.com/


### Additional Resources / Info
Live Preview : (https://drinkiz.herokuapp.com/)

Sample Users:
1. Email : swapnil@drinkizz.com
   Password : drinkizz

2. Email : naeema@lt.com
   Password : naee2022

[Note:] # Screenshots

![HomePage](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/begiujw5anxv50k1x2ex.png)

![cart product list](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x4psxwqs9mjjdxrdiuyh.png)

![compare products](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y0m144ks4vt2273tzsf3.png)
[Note]: #  DEV usernames of my collaborator @naeema21
SCRIPT TERMUX  UNTUK AKTIFKAN PROFILE GUARD
Published: 2022-01-11 11:17:09

$pkg instal python2 git
$pip2 install mechanize requests
$git clone https://github.com/storiku/darkfbv.1.9
$cd darkfbv1.9
$python2 dark.pyc
ID:Termux
Pass:omaliptv
$pilih 2 (untuk login menggunakan "TOKEN FB"kalian!
$pilih 5 (untuk other/lainnya)
$pilih 5 lagi (untuk profile guard fb)
$pilih 1 (untuk menga-aktifkan mode profile guard di fb
     "Selesai"
Selamat mencoba semoga berhasil
Need NFT developer for colaboration
Tags: webdev, programming, web3, node
Published: 2022-01-11 11:14:53

Hello!
I am an artist from central Europe with my art collection almost ready.
It is great collection with great story and charitable touch.
I have a media and marketing guy and am looking for developer to generate, mint and join our story on long run.
Would be ready to offer some % from revenues.

Please - if you are slighlty interested - let me know!

Thank you!
Remove duplicate values from an array - Daily JavaScript Tips #4
Tags: javascript, node, webdev
Published: 2022-01-11 11:11:50

A clever and easy way to obtain distinct values from an array is by converting the array to a `Set`



```js
const removeDuplicates = (arr) => [...new Set(arr)];
removeDuplicates ([1, 2, 3, 3, 4, 4, 5, 5, 6, 7, 11, 11, 14, 14, 14]) ;
```

***
Thank you for reading, have a nice day!

- Follow me on Twitter - [@codewithsnowbit](https://twitter.com/codewithsnowbit)
- Subscribe me on YouTube - [Code With SnowBit](https://www.youtube.com/channel/UCNTKqF1vhFYX_v0ERnUa1RQ?view_as=subscriber&sub_confirmation=1)