teleren/devto huggingface dataset:
In Windows (10), how to configure global proxy settings for all network connections and not just 'the internet'?
Tags: help, windows, global, proxy
Published: 2018-05-05 00:00:17

---
title: In Windows (10), how to configure global proxy settings for all network connections and not just 'the internet'?
published: true
description: Configuring proxy settings in Windows that apply to everything.
tags: help, windows, global, proxy
---

I run a squid proxy server on some Ubuntu machine. I use a Windows 10 client with Google Chrome to surf anonymously and watch dirty videos. 

Both Microsoft browsers and Chrome's proxy settings point to _Internet Options_ of Windows. Firefox has its own settings that lets you configure your proxy only for Firefox.

![Internet Options](https://thepracticaldev.s3.amazonaws.com/i/qqnz13pk35e227u2pog3.png)

Many applications (like cmd.exe, WinSCP, putty, mIRC, Node, youtube-dl, ...) ignore the proxy configuration from internet options and connect directly.

If I go to [https://api.ipify.org/?format=json](https://api.ipify.org/?format=json) in a browser, the IP address in the response is that of my proxy like expected but if I run [ipify](https://www.npmjs.com/package/ipify-cli) from the command line (which simply makes a http request to the same url) it shows the client's (my) ip address.

Most applications allow you to configure a proxy but not all of them. To prevent the pain of having to configure proxy settings for every single application and the agony of wrapping, sandboxing or virtualizing those that have no proxy settings I figured we can probably change proxy settings somewhere on the level of operating system.

![Proxy Settings](https://thepracticaldev.s3.amazonaws.com/i/kkfqybqw7kauu16emdhy.png)

The configuration here reflects that of internet options. They are the same settings just two screens to edit them.

## How do I configure a 'global' proxy that applies to all connections in every application?
How to Bind 'this' in React Without a Constructor
Tags: react, beginners, javascript
Published: 2018-05-04 23:33:47

---
title: How to Bind 'this' in React Without a Constructor
published: true
description: React doesn't auto-bind this to custom methods. Usually you would use a constructor function to accomplish this. But do you need one?
tags: react, beginners, javascript
---

![](https://thepracticaldev.s3.amazonaws.com/i/a8j2ie73e5ux4fspnog0.jpg)


*This post was originally on [my blog](https://tiffanywhite.tech/bind-this-without-constructor/)*.

`this` in React is a reference to the current component. Usually `this` in React is bound to its built-in methods so that when you want to update state or use an event handler on a form, you could do something like this:

```javascript
<input type="text" ref={this.someInput} required placeholder="This is a Method" defaultValue={getSomeMethod()}/>
```

where `this.someInput` is passing state to whichever React component you are rendering.

Unfortunately, though, React doesn't auto-bind `this` to custom methods. This means if I wanted to manipulate the DOM by getting some input, which you can't do as you can with normal JavaScript, I would create a `ref` to do whatever DOM tinkering I wanted.

But because React doesn't auto-bind `this`, the following code would output undefined when logged:


```javascript
someInput = React.createRef();
  renderSomeInput (event) {
    event.preventDefault();
    const someFunction = this.someInput.current.value;
    console.log(this);
  }
```
In order to avoid this, we could use the `constructor` function in order to render the component or get the state we want:

```javascript
class SomeCompenent extends React.Component {
   constructor() {
    super();
    this.renderSomeInput.bind(this);
   }
}
```

While this is a decent way to render a ref on a component, what if you wanted to bind several custom methods in one component? It would get pretty messy...


```javascript
class SomeCompenent extends React.Component {
   constructor() {
    super();
    this.renderSomeInput.bind(this);
    this.renderSomeInput.bind(this);
    this.renderSomeInput.bind(this);
    this.renderSomeInput.bind(this);
   }
}
```

You get the idea.

Instead, we can bind `this` to custom React methods by declaring a method by assigning it to an arrow function:

```javascript
class SomeCompenent extends React.Component {

someInput = React.createRef();
  renderSomeInput = (event) =>  {
    event.preventDefault();
    const someFunction = this.someInput.current.value;
    console.log(this);
  }
}
```
which will allow us to bind the value of `this` to the `SomeComponent` component.

## Hope This Helps!

ES6 gave us classes and constructors and React utilized them right away. You don't *always* need a constructor, and it helps to know when to use one and when not to.
Software engineering vs Coding
Tags: softwareengineering, coding
Published: 2018-05-04 22:51:31

---
title: Software engineering vs Coding
published: true
description: One of the main difference is that the former has a formal process while the later maybe not.
tags: softwareengineering, coding
cover_image: https://thepracticaldev.s3.amazonaws.com/i/1qlku3ukyiufdg5ecseg.png
---

One of the main difference is that the former has a formal process while the later maybe not. Let's take a simple example. Let say you discover a bug, (or our customer did) where a date was displayed in wrong format. If you just do mere coding, what would you do probably just get into the production server and edit the code live in production ! You get the job done and it's all that matter.

But in software engineering process, it's more than that. First you write a test, or figure out some way to reproduce the bug. Then you file a bug report in relevant place, detailing together all your investigation and your conclusion about the bug, with the test you wrote as supporting document to prove that this indeed a bug. Together in the bug report, you also lay out your plan on how to fix the bug.

Discussion will ensue in the bug report, with others also chime in giving out their idea on how to fix the date format bug. You create a new branch and commit your changes. You run all the tests to make sure the changes doesn't break any other parts. After that, you open a PR for the changes to be merged to master. Someone else will review your PR, and might point out that your code not following PEP8. So you rework the changes and ask for another round of review. This time your changes get approved and merged to master. Are we done ?

No ! When the changes get merged to master, another round of tests need to be run against the master to make sure no unexpected breakage. Once that done, you have to  update the changelog and create new release. You then deploy the new release to production. Are we done ? Still no. You have to update the ticket to mentioned that the changes has been deployed to production. If we get no more issue after that, the ticket will be closed and only after that we're done.

And that's for fixing a wrong date format. Of course in practical, for some small changes (especially an urgent one), we have what being called hotfix, that would sidestep most of the process mentioned above. But the bottomline is, in software engineering, we have a formal process in bringing out the code, and it's not just code that involve. And this is just one changes. What if you have 2 or more related and non-related bugs ?
A MAZE in Berlin - my impressions
Tags: amaze, berlin, indie, gamedev
Published: 2018-05-04 20:51:54

---
title: A MAZE in Berlin - my impressions
published: true
tags: amaze,berlin,indie,gamedev
canonical_url: http://asawicki.info/news_1680_a_maze_in_berlin_-_my_impressions.html
---

Last week I've been on [**A MAZE**](http://amaze-berlin.de/) - an event in Berlin advertsed as "7th International Games and Playful Media Festival". I went there together with a large group of people from [Polygon](http://polygon.pw.edu.pl/) - gamedev interest group from Warsaw University of Technology. I liked it a lot because it's something different from what I've attended before, and I've been on many events, like gamedev conferences (e.g. GDC), demoscene parties (e.g. Revision), gaming expo (e.g. Poznań Game Arena), cybersport events (e.g. World Cyber Games), or events decated to retro computers.

A MAZE could be described as independent games festival. Majority of events took place between Thursday and Saturday. Its main part was game exhibition, where booths with many games were available for visitors to play or talk to their developers. They were indie games, so either very artistic, containing some original gameplay ideas, unusual controller, or somehow politically involved. Contrary to expo at GDC, there were no AAA titles, no big publishers, IHVs or middleware developers. There were some really polished and commercially successful games though, e.g. SUPERHOT.

Second big part of the event were talks happening on two stages. Again, they were very "alternative", often delivered by artists or academics. They either discussed some ideas or artistic vision behind some game, touched politics (of course all from the left side of political scene, e.g. about helping migrants, women, and other minorities), or they were purely fun. There was very little about programming and nothing about advanced rendering technology. Most of indie developers use Unity. I attended one of the workshops about Unity, but it was very basic - speaker explained what is `bool`, `int` etc.

Besides, there were concerts every evening with bands or DJs playing, VJs making visualizations, lots of beer and other festival fun :) I recommend attending A MAZE at least once to anyone interested in games or game development, just because it's so different from other events. Plus it happens in Berlin, and I love the atmosphere of this city :)
Desvirtualización, de developer a comercial
Tags: spanish, perspective, developer
Published: 2018-05-04 20:42:17

---
title: Desvirtualización, de developer a comercial
published: true
description: Como dejar de programar me ayudó a ser mejor developer.
tags: spanish, perspective, developer
---

![Images from Google](https://thepracticaldev.s3.amazonaws.com/i/xodz96qzry63vgljazcx.png)

Siempre me he considerado la típica developer que cruzó al lado oscuro, de IT a Commercial, del fullstackear a tomar llamadas de clientes; creo que esto mejoró mi lógica como developer.

Ahora que pertenezco al área comercial me doy cuenta de la ventaja de haber estudiado ciencias y de haber trabajado como developer. Hoy en día utilizo estrategias de desarrollo para actividades “comunes” que requieren organización y resolución de problemas efectivos.

Por ejemplo, existe una buena práctica (en el área de TI) que consiste en modular un desarrollo, modular código consta básicamente de descomponer tu programa en partes para formar uno o más elementos con la finalidad de hacerlo más perceptible o mantenible. 


![Fuente: StackBlitz](https://thepracticaldev.s3.amazonaws.com/i/espizncvz8ep6zfactn5.gif)

Bueno, pues descubrí que puedes modular todo, desde un correo para obtener una lista de necesidades de un cliente o puntualizar las dudas que tiene un usuario bajo determinada situación hasta crear un esquema de pasos a seguir o pendientes en la relación con el cliente. 

Aunque usar técnicas de desarrollo me ha ayudado en mi rol comercial, también ha pasado al contrario, es decir, estar en el área comercial me ha dado un contexto más amplio de lo que ocurre en relación al cliente o usuario final y esto es vital a la hora de construir el producto ideal. Pasa que cuando escuchas de primera mano las quejas o dolores de los clientes indirectamente mejoras tus skills en UX. 

![Fuente: Desktop](https://thepracticaldev.s3.amazonaws.com/i/no9edls4qmimi3l4sm5s.gif)


Creo que como developers obviamos conceptos y olvidamos toda la información del perfil de usuario, generando conflictos o molestias por parte del usuario. (la lógica del developer está muy enfocada a resolver un problema pero no siempre están pensando en experiencia de usuario y esta perspectiva te la da el estar en contacto con clientes, sobre todo para compañías que no son tan grandes y no tienen un área de UX)

# ¿Por qué desvirtualización?

Desde mi perspectiva, para trabajar directamente con el cliente/usuario hay que cambiar de chip siempre ser más empática, clara y hasta metafórica; ser consciente que no siempre se tiene razón y que no todos conocen la terminología técnica. A esto lo llamo deslinde del mundo geek o virtual, es decir, desvirtualización.
What programming sub-disciplines seem to be trending up in terms of career options?
Tags: discuss, career
Published: 2018-05-04 20:11:56

---
title: What programming sub-disciplines seem to be trending up in terms of career options?
published: true
description: 
tags: discuss, career
---

Which types of roles are gaining momentum in our field? What are the jobs that seem to be the most in demand and will continue to grow?

You don't have to know for sure, but I'd love to hear any thoughts.
Stadia Maps | Google Maps Platform alternative
Tags: maps, geographicservices, showdev, webdev
Published: 2018-05-04 18:39:56

---
title: Stadia Maps | Google Maps Platform alternative
published: true
description: A brief overview of Stadia Maps
tags: maps, geographic services, showdev, webdev
---

Hello Dev.to 👋

We're [Stadia Maps](https://stadiamaps.com), a bootstrapped provider of map tiles, static maps, and routing. We've been in operation for about a year, but only open to the public for a few months.

We offer:

- raster & vector map tiles 
- static maps
- routing

With the new Google Maps Platform pricing, we want to reiterate our commitment to transparent pricing, simple integration, and privacy-respecting services. I'll be around to answer questions as you have them.

We also want to learn from you:

- How do you use maps?
- What do you wish you could do with a map?
- What is your biggest pain-point with using maps?

Happy mapping! 🗺
Introducing our May 2018 sponsors
Tags: meta
Published: 2018-05-04 17:47:50

---
title: Introducing our May 2018 sponsors
published: true
description: Our wonderful sponsors are vital to the health of dev.to and it is great to work with companies contributing so much to the ecosystem.
tags: meta
cover_image: https://thepracticaldev.s3.amazonaws.com/i/0vghhjlq7l4aw5hmihjx.png
---

We are proud to announce our sustaining community sponsors for May. Our wonderful sponsors are vital to the health of [dev.to](https://dev.to) and it is great to work with companies contributing so much to the ecosystem.

# Pusher

[Pusher](https://pusher.com/?utm_source=dev.to&utm_medium=referral&utm_campaign=Devtocontest) is our first _Platinum Sponsor_, which means we are doing a super special partnership with them. That takes the form of the [Pusher Contest](https://dev.to/devteam/first-ever-dev-contest-build-a-realtime-app-with-pusher-4nhp).

We are using Pusher ourselves to build out several realtime features for [dev.to](/). Pusher is a super well-respected engineering organization and we're pumped to build on their infrastructure.

## Digital Ocean

[Digital Ocean](https://try.digitalocean.com/performance/?utm_source=devto&utm_medium=display&utm_campaign=Devto_2018_Brand) is a much-loved cloud computing platform. I'm always impressed by how well-built _and well-documented_ the Digital Ocean core products are. It's easier said than done, and they've been able to stay ahead of the curve.

Digital Ocean is so easy to get going with, it could pair with your Pusher contest entry for hosting your app's cloud presence. Just an idea. 😄

## Bugsnag

[Bugsnag](https://www.bugsnag.com/?utm_source=dev.to&utm_medium=cpc&utm_content=recognition_post&utm_campaign=dev.to-2018-may) provides error monitoring for web, mobile, and server apps. It is lightweight on the frontend and very sophisticated on the backend. It integrates with pretty much everything and has a free tier. All around great people on the team as well. 

Seriously, great monitoring is so vital to sleeping well at night. Check out Bugsnag.

## Timber

[Timber](https://timber.io/?utm_source=devto&utm_medium=homepage&utm_campaign=devto_may) is one of the most interesting products to take on the logging space. Built around readability and usability, Timber is a logging system you're actually going to be excited about using. We have been Timber users since the beta days ourselves _and we now share an office space with them_. They are doing great work.

Timber currently integrates most seamlessly with Ruby, Elixir and Node applications. It comes highly recommended from our team.

***

These organizations are helping us build the best community we can. I urge you to check out their offerings if you are in the market for their services.

Happy coding ❤️
objects? No... array, please!
Tags: javascript, arrays, object, beginners
Published: 2018-05-04 17:44:37

---
title: objects? No... array, please!
published: true
description: Use array, instead of an object
tags: javascript,arrays,object,beginners
---

#I don't like objects...that much!

This is an _object_:

```js
const obj = {breed:"labrador",age:9}
```

But sometimes I prefer to work with arrays.

Why? Because they really look better **to me**... and there are really a lot of methods or loops that work _just_ with [arrays]!

These are some tools used to _"convert"_ objects to arrays.

```js

//Object.values() will give you an array of all the object "values"

const obj = {breed:"labrador",age:9}

const values = Object.values(obj)

console.log(values)

//-> ["labrador", 9]



//Object.keys() will give you an array of all the object "keys"

const obj = {breed:"labrador",age:9}

const keys = Object.keys(obj)

console.log(keys)

//-> ["breed", "age"]



//Object.entries()  will give you an arraysh version of the object. 
//Where the key and the value will be paired into an array... 
//and all of those arrays will be "pushed" into another array.

const obj = {breed:"labrador",age:9}

const entries = Object.entries(obj)

console.log(entries)

//->[["breed", "labrador"], ["age", 9]]


```

This is _easy peasy_ stuff, but very often, at the beginning of my journey in _JS_, objects were very often a problem for me.

If only they had told me before ...

<center>![img](http://static.yourtango.com/cdn/farfuture/6HjAhU1pGFNDKoarYIDtEGMvpAPpSjYWMm6xn0ZlrJw/mtime:1475815278/sites/default/files/notyourfault.gif)</center> 



**P.S: These tools are ok... if it’s ok to work with arrays instead of objects.
Sometimes you’ve to use objects... because of performance or long term maintenance.**
Static Analysis in Video Game Development: Top 10 Software Bugs
Tags: cpp, opensource, csharp, gamedev
Published: 2018-05-04 13:32:44

---
title: Static Analysis in Video Game Development: Top 10 Software Bugs
published: true
description: 
tags: cpp, opensource, csharp, gamedev
---

If you are a software developer working in the video game industry and wondering what else you could do to improve the quality of your product or make the development process easier and you don’t use static analysis – it’s just the right time to start doing so. You doubt that? OK, I’ll try to convince you. And if you are just looking to see what coding mistakes are common with video-game and game-engine developers, then you’re, again, at the right place: I have picked the most interesting ones for you.

One of the best ways to prove that static analysis is a useful method is probably through examples showing it in action. That’s what the PVS-Studio team does while checking open-source projects. After publishing of various articles, we compiled our top-10 mistakes from the program code in the video-game industry, and now we suggest you read this article - https://www.viva64.com/en/b/0570/

List of projects considered in the article:

- X-Ray Engine
- CryEngine V
- Space Engineers
- Quake III Arena GPL
- Unity
- Godot
- Doom 3
- Xenko
-Unreal Engine 4

Although video-game development includes a lot of steps, coding remains one of the basic ones. Even if you don’t write thousands of code lines, you have to use various tools whose quality determines how comfortable the process is and what the ultimate result will be. Static analysis is a very useful tool when developing, and one more option to help you improve the quality of your code (and thus of the final product).
Tech Events this Week - 5/7
Tags: discuss, career, eventsinyourcity
Published: 2018-05-04 16:37:25

---
title: Tech Events this Week - 5/7
published: true
description: Let's crowdsource tech events going on in different areas!
tags: #discuss, #career, #eventsinyourcity
---

Each week for my students, I create a newsletter that lists the tech events going on in DC that I've heard about. I thought it would be really cool to expand that to a bigger community and crowdsource it for other people to contribute.

I am going to put some comments below with different areas, feel free to reply with your events on those comments. **If you have an event that isn't in one of those areas, feel free to first write a comment with the area, then another one threaded onto it with your event!**

I will be posting this thread every Friday!
Learning Generative Art; day 5 "Unknown Language" 👁‍🗨
Tags: beginners, art, graffiti, showdev
Published: 2018-05-04 16:08:48

---
title: Learning Generative Art; day 5 "Unknown Language" 👁‍🗨
published: true
description: I drew an image expressing a feeling with p5
tags: beginners,art,graffiti,showdev
cover_image: https://thepracticaldev.s3.amazonaws.com/i/8u1v4re8l7oup6xuv3b2.png
---

Continuation of [My first step in learning Generative Art](https://dev.to/ohbarye/my-first-step-in-learning-generative-art-3674).

## "Unknown Language"

![gif](https://thepracticaldev.s3.amazonaws.com/i/2fp6w693c6t5bgowaxrn.gif)

![image](https://thepracticaldev.s3.amazonaws.com/i/8u1v4re8l7oup6xuv3b2.png)

I've tried to express what I feel in a situation of facing an unknown language. On that occasion, I never understand what strangers say, what they think, what they feel. Then I feel incredibly isolated and my eyesight turns out gray.


```js
var xoff = 0.0;
var words = ["Lorem", "ipsum", "dolor", "sit", "amet,", "consectetur", "adipiscing", "elit,", "sed", "do", "eiusmod", "tempor", "incididunt", "ut", "labore", "et", "dolore", "magna", "aliqua.", "Ut", "enim", "ad", "minim", "veniam,", "quis", "nostrud", "exercitation", "ullamco", "laboris", "nisi", "ut", "aliquip", "ex", "ea", "commodo", "consequat.", "Duis", "aute", "irure", "dolor", "in", "reprehenderit", "in", "voluptate", "velit", "esse", "cillum", "dolore", "eu", "fugiat", "nulla", "pariatur.", "Excepteur", "sint", "occaecat", "cupidatat", "non", "proident,", "sunt", "in", "culpa", "qui", "officia", "deserunt", "mollit", "anim", "id", "est", "laborum"];

function setup() {
  createCanvas(800, 400);
  background(220);
  noStroke();
}

function draw() {
  fill(220, 4); // Create an alpha blended background
  rect(0, 0, width, height);

  // Get a noise value based on xoff and scale 
  // it according to the window's width
  var n = xoff * xoff * width;
  // var n = random(0,width);  // another expression

  xoff += 0.01; // With each cycle, increment xoff
  if (n > width) {
    xoff = 0.0; // reset
  }

  fill(color(random(100, 133), random(250), random(200, 255), random(200, 255)));
  ellipse(n, random(height), random(64), random(64));
  text(random(words), n, random(height));
  textSize(random(8, 24));
}
```

## TIL 📝

### `noise`

[`noise` function](https://p5js.org/examples/math-noise1d.html) is another way to introduce randomness into generative art. `noise` uses [Perlin Noise](https://en.wikipedia.org/wiki/Perlin_noise) unlike `random`. It means that we can express more natural texture or behavior than `random`.

(By the way, I didn't know `random` function accepts an array as its argument.)