teleren/devto huggingface dataset:
Why Go succeeded; Java's naming conventions; & Python optimization tips
Tags: todayilearned, go, java, python
Published: 2019-11-19 13:00:09

*TL;DR style notes from articles I read today.*

### [5 things Rob Pike attributes Go’s success to ](http://bit.ly/2rZlAwt)

- Writing a formal specification of the language.
- Making Go attractive for app developers to use. Having key software written in Go created confidence in it. 
- Establishing a strong open-source community that supported Go. Being prepared for a tricky balancing act while listening and implementing.
- Counterintuitive, but making the language hard to change. Yes, it creates rigidity but also makes it harder for old code to break.
- Constantly listening to the community, but sticking to the things Go team believed are important from their specs. 
  

*[Full post here](http://bit.ly/2rZlAwt), 4 mins read*

---
### [What’s in a name: Java naming conventions](http://bit.ly/2Qsa07b)

- In the base package name, put your company’s domain in reverse order & then add the project name & maybe version - all in lower case.
- Use nouns, written in CamelCase (with first letter capital), for class names. Class names should say what function or variable to expect from it as well. 
- Choose short, meaningful nouns for variables and fields, saying what values or variables they hold, in camelCase. 
- Avoid single character variables. Avoid underscore & dollar as first letters. For boolean values, start with ‘is’ or ‘has’, since they are yes/no questions. 
- Put constants in all-caps, with underscores to separate words.
- Make methods and functions verbs, implying what they do in 2-3 words in camelCase. Use ‘get’ & ‘set’ to start the names of data fetching and setting functions.
- Use similar conventions as classes and interfaces for enums and annotations, respectively, with enums in all-caps.

*[Full post here](http://bit.ly/2Qsa07b), 5 mins read*

---

### [Python code optimization tips for developers](http://bit.ly/2KA1EGE)

- Optimize the slow code first. In the case of Python, PyPy helps you use less space and work faster than CPython’s typical bulk allows for.
- Profile codes (using CProfile or PyCallGraph, say) to analyze how they work in different situations and estimate the time taken.
- Python strings tend to be immutable and slow. Concatenate them with the .join() method rather than relying on the memory-hungry (+) operator alone.
- Use list comprehension rather than loops for faster coding and execution.
- For memory optimization, prefer xrange over the range function to speed up the creation of integer lists. 

*[Full post here](http://bit.ly/2KA1EGE), 4 mins read*

--- 

*[Get these notes directly to your inbox every weekday by signing up for my newsletter, in.snippets(), here.](https://mailchi.mp/appsmith/insnippets?utm_source=devto&utm_medium=post08&utm_campaign=is)*
How I Stopped to Write CSS
Tags: css, webdev, opensource, tailwindcss
Published: 2019-11-19 12:57:13

As a frontend developer focused on the CSS architecture, I like to use the best methodologies to write my code. I always do research to understand the frameworks that suit my needs and can be scalable.

A few months ago talking with my colleague the name of a CSS framework came out: **Tailwind CSS**.

Usually, I used Bootstrap for most of my projects, but a few weeks ago, I started to use Tailwind and it completely changed my way of using CSS.

##What is Tailwind CSS
As we can read on the official website:
_Tailwind CSS is a highly customizable, low-level CSS framework that gives you all of the building blocks you need to build bespoke designs without any annoying opinionated styles you have to fight to override._

The truth is that many CSS frameworks have too many components predesigned and many times we are forced to **overwrite** them, especially when we work with highly customized UIs.

Instead of predesigned components, Tailwind provides utility classes that let you build your custom designs without **ever leaving your HTML**.

**Let’s look at some examples of how my way of writing CSS has changed since I started using Tailwind.**

Now I would like to show you an example of creating a card component using Tailwind and only CSS.
It’s impressive to see how you can create a component like this **without** even **a line of code**.

Do not you believe it?
I will prove it with a practical example.

Continue to read on Medium 👇🏻


{% medium https://medium.com/notonlycss/how-i-stopped-to-write-css-58c40e53967e %}
How often you use algorithms in your daily coding ?
Published: 2019-11-19 12:54:20

I started my career as a Linux System Administrator and then switched to Application support engineer and did both System & Application support later. In this time period I had learned some Python and Bash.

Now I switched to Infrastructure automation developer and working with JS & Bash. So, I have been hearing about Algorithms these days but I wonder how much they will be useful for me. 

Any suggestions are greatly appreciated.

Thank you.
Raja.
End of an era?!
Published: 2019-11-19 12:35:59

Mirantis acquires Docker!
![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/nr25mincbjunp5lfe7vj.png)

The complete thread can be read here:
https://analyticsindiamag.com/mirantis-docker-acquisition-enterprise-kubernetes-containers/

#docker #mirantis #discuss
Weekend Challenge - Airport
Tags: makers, rspec, ruby
Published: 2019-11-19 12:33:51

So over the weekend, we were given the challenge of making an airport programme. It had to consist of classes and methods, we had to write an RSpec file for it too. This wasn't too hard tho because it was similar to the Boris bike challenge. The weekend challenges seem to build what we learned throughout the week, which ensures we fully understand the things we learned and lets us know what we need to work on.

I didn't have too much trouble with this challenge. I think I need to get used to RSpec and classes mainly. I got everything done except preventing the plane from landing in a different airport if it was already another airport. Which I realised in the morning was because I should've put the land in the plane class. I seem to be struggling with splitting up the classes which I'll work on this week.

We also did pair-reviews on Monday which was helpful because I got a chance to see how someone else did the challenge and some of their code could’ve solved my problem. It was refreshing getting a different perspective on the same challenge. They also showed me the *"before"* block in RSpec which would have stopped me repeating myself so much. The *"before"* block runs the code in it before doing the tests under it. I think this is a brilliant way of checking your code because it can reveal any blind spots.
YPSKA #8 Headless CMS
Published: 2019-11-19 12:25:03

As a natural evolution with both SPA-sites and JAM stack sites, headless CMS has started to gain traction. A headless CMS is basically WordPress without the UI. You use an API to access the pages and the UI to create/edit pages can be external. There's two main kinds of headless CMSs, API-based or Git-based, and this distinction mostly has with how you store the documents in your CMS. Either you use some kind of API or you just store the documents in a Git repository.

As with yesterdays topic [Static Website Generators](https://dev.to/hfahlstedt/ypska-7-static-site-generators-33gj), there's a comprehensive [list](https://headlesscms.org/) of available headless CMS products. So go ahead and try one out!
The PHP 7.4 guide (new features)
Tags: php74, typedproperties, spreadoperator, arrowfunction
Published: 2019-11-19 11:58:39

---
title: The PHP 7.4 guide (new features)
published: true
description: Discover the new features of PHP 7.4 the next version of your favourite language 
tags: Php7.4, TypedProperties, SpreadOperator, ArrowFunction
cover_image: https://anastasionico.uk/img/blog/php-7-4-new-features.jpg
---

Beginner developers on the facebook group often ask me questions like:

What is the next amazing tool they need to learn?
Which PHP framework is the best and easiest to start with?
How to implement ci/cd on AWS or CircleCi?

My answer is simply this – don’t worry about it.

When you're just starting to learn how to code, you naturally want to try any possible tool or framework,

it is a requirement to get a job so it seems reasonable to do that.

Except it is not!
That is actually a really (really) bad idea.

Let me quickly explain why.

Firstly, if you don't know the basics of PHP, I mean the core language, there is no point on using components from packagist because you wouldn't understand them

Secondly, if you know the principles of how the MVC paradigm and a PHP framework work, it will take less than a week to switch between them.


Here's a key principle to remember: top-level developers are the ones who decide which tools NOT to use.

Get a senior developer on your team and ask what are his experiences working with support platforms, various components from GitHub and similar.

Grab a coffee beforehand, cause you'll hear a long answer!

Now, imagine all the extra time you spend online looking for a solution that eventually could have been wrote using a simple PHP built-in function that takes 30 seconds to be written.

Being a top-level developer is about having the ability to write the RIGHT code and use the RIGHT tool only when needed.


To progress with web development, you got to be super picky with your time.

Any now and then the core PHP developer's team comes out with a new release, a new version of the language of which all the tools are built around.

These new versions usually include new features that will make your code easier to write and to read,

deprecations of old function and dangerous technology (sha1 anyone?), and other changes on the code and practices


PHP 7.4 is coming ...

The next version of PHP is just a few days away, and it is bringing new features that will be an important part of PHP 8 just a couple of years down the line.

Staying up-to-date with the core language is the only reason you can keep up with your colleagues, get a new job, learn the concept of the new fancy stuff easily and deploy your code quickly.

In this and the following posts, you are not only going to learn what the new features of PHP 7.4 are, 

You will learn what the contributors to the components and frameworks that you like the most will use in the next coming years.

[**Read the full article here**](https://anastasionico.uk/blog/php-7-4-new-features)
How to define a JavaScript function
Tags: javascript, notetomyself
Published: 2019-11-19 11:31:53

As I always have a little trouble remembering everything and also because there is a little collection side that I like, here is a summary of the different ways that exist to define functions in JavaScript.


## Through a declaration

The classic method dates back to the origins of JavaScript and simply consists of declaring the function with the keyword `function`.

```javascript
function hello (firstname) {
  console.log(`Hello ${firstname}`);
}
```

This function has the name "hello", which makes it a named function.


## Through an expression

A more modern method that highlights the fact that functions are objects like any other and can also be assigned to variables.

```javascript
const hello = function (firstname) {
  console.log(`Hello ${firstname}`);
};
```

Even if this is not obvious, this function is anonymous:

* It is created without giving it a name (just "function (...) { ... }")
* Although it is assigned to a variable that has a name

Note: Since this is an assignment to a variable (in this case it's a function that is assigned), the command ends with a semicolon, exactly as is the case for all other assignments: `const pi = 3.14;`.


## Through the arrow syntax

With ES6 came the new syntax "arrow" to declare functions via an expression:

* Remove the keyword `function` before the list of arguments.
* Add the symbol `=>` after this list.

```javascript
const hello = (firstname) => {
  console.log(`Hello ${firstname}`);
};
```

It's more compact and the goal is to get a cleaner code. This is why arrows functions can be further simplified:

* Only one parameter => no need to put it in parentheses.
* Only one line of code in the function => no need for a block "{ ... }".
* If the function only makes a "return..." => the keyword `return` is useless.

In the end, the following three declarations are identical:

```javascript
const hello1 = function (firstname) {
  return `Hello ${firstname}`;
};

const hello2 = (firstname) => {
  return `Hello ${firstname}`;
};

const hello3 = firstname => `Hello ${firstname}`; // (°~°)
```

This clean aspect is really useful for callbacks. For example, with the `.map()` method of tables that expects a callback function, you can get some interesting stuffs:

```javascript
const test = [1, 2, 3];

function doubler (x) {
  return x * 2;
}
test.map(doubler);                          // [2, 4, 6]

test.map(function (x) { return x * 2; });   // [2, 4, 6]

test.map((x) => { return x * 2; });         // [2, 4, 6]

test.map(x => x * 2);                       // [2, 4, 6] Bingo!
```

This post was originally published on my [blog](https://blog.pagesd.info/2019/11/19/how-to-define-javascript-function/).
Cover image : [Wall decorations with colorful butterflies - __ drz __](https://unsplash.com/photos/X8pnAEjqmqI).
Sector Survival: A hyper local survival game
Tags: unreal, game, development
Published: 2019-11-19 11:20:20


![Logo pic](https://thepracticaldev.s3.amazonaws.com/i/bortg3u20jcs2by9uic7.png)


### Introduction:

This past month I've been playing with unreal engine,by making a small first person shooter game. Moving on, I've decided to do a small RPG which involves more complex game login (user decisions).

Sector survival will be a hyper local game focused on [sector 10, in the city of Chandigarh](https://www.google.com/maps/@30.7537476,76.7885076,15z). Hyper local means that the game world is modeled on a specific part of a real city as it is now. 


### Process:

- Design of game assets
- Level Design
- Logic

### Concept:
 A hyper local social survival strategy game.

### Objective: 
To survive a minimum of 20 mins of game play with a base popularity score for example 65% popularity

### Summary: 
An RPG. The pawn/main character is situated in sector 10, located in the city of Chandigarh. The city is known for new money, students, and display of wealth. The pawn must accumulate a reasonable popularity score (65%) to move on to the next level/sector by playing against complex social rules with limited resources such as energy, health and money.
There are lots of choices and dialogues
Some action like GTA example driving, shooting

### Game world: 
The game world will model sector 10 as it is now. The road map, market place will be the same.

### Pawn features:

 - Health: 
 ```
 - shot/fight
 - shot/fight
 +  buy medicine, heal with time
```

- Money:

```
 - loan money, spend money on restaurant, food, medicine, gas 
 +  sell drugs (- popularity )
```

- Popularity: 

```
 - fight, sell drugs, get caught speeding
 + loan money, take someone out on a date (- money), give someone a lift (- time)
 - fight, sell drugs, get caught speeding
```

### USP:

0. Hyper local game which means the game world is modeled on a specific part of a real city as it is now
2. The characters will be modeled on real people within the city
3. The characters will speak punjabi
4. The game emulates the local culture hence enticing people to spend time within the game
How we hire top talent – Inside The Studio
Tags: insidethestudio
Published: 2019-11-26 15:38:15

---
title: How we hire top talent – Inside The Studio
published: true
date: 2019-11-19 11:02:47 UTC
tags: Inside The Studio
canonical_url: https://steadfastcollective.com/articles/how-we-hire-top-talent/
cover_image: https://steadfastcollective.com/app/uploads/2019/11/Steadfast2019-79.jpg

---

<iframe src="https://www.youtube.com/embed/PAhxexi81tM" width="560" height="315" frameborder="0" allowfullscreen="allowfullscreen"><span data-mce-type="bookmark" style="display: inline-block; width: 0px; overflow: hidden; line-height: 0;">﻿</span></iframe>

In this week’s Inside The Studio episode, we chat through hiring in an agency context.

We’re worked hard to develop our team of smart creatives, and we’re proud of our team!

We wanted to share our top hiring tips on how we grew that team.

_Before we jump into that; have you subscribed to our YouTube channel or podcast stream yet? _

[YouTube](https://www.youtube.com/channel/UC2wqdXFTQRDh2ZamjoH3NHQ?view_as=subscriber) – [Spotify](https://open.spotify.com/show/3C2Wi9oB1JsdNHgwZxuYYT) – [Apple Podcasts](https://podcasts.apple.com/us/podcast/the-steadfast-collective/id1380783502)

#### 1) Run events.

Through running events in our local area, we’ve hired two people. By being present and active in your local community, you’re likely to meet likeminded folk who, if you make a good connection with, will reach out next time you’re hiring.

If you’re not quite ready to run events, go to other events! Hiring will always be easier if you have a more extensive network.

#### 2) Focus on smart. Not skillset.

> You can teach skills; you can’t teach smart.

As you run your business, you gain a sixth sense for talent. When I re-met Josh at a wedding, he told me how he hated his job and would love to become a game developer.

I knew Josh’s integrity, and intelligence was there, just the skillset for development that was missing.

Josh spent the first six months at Steadfast learning to code while being our project manager. Josh now is a talented developer working on client projects daily.

#### 3) Being transparent

Be honest from the offset. We always publish salaries on our job adverts, we feel this sets the tone for the culture of openness we expect at Steadfast Collective.

We always interview in our office, again we don’t want to hide anything about what makes us Steadfast.

These three things have helped us develop into a team of seven, ensuring we have built our core ideas into every section of the business.

<iframe src="https://player.simplecast.com/eae47b9f-ed08-4754-a707-2ec7cd92bbaf?dark=false" width="100%" height="200px" frameborder="no" scrolling="no" seamless=""></iframe>

The post [How we hire top talent – Inside The Studio](https://steadfastcollective.com/articles/how-we-hire-top-talent/) appeared first on [Steadfast Collective](https://steadfastcollective.com).
Force Login for Magento 2 by FMEextension
Published: 2019-11-19 11:00:22

---
title: Force Login for Magento 2 by FMEextension
published: true
description: 
tags: 
---

<img src="https://thepracticaldev.s3.amazonaws.com/i/f1njp9w8kcsxtn82dbe1.png"/>
<p><b><a href="https://www.fmeextensions.com/magento-2-cancel-order-by-customers-extension.html">Magento 2 Force Login Extension</a></b> is a complete solution to stop undesireable users get access to Product,Category & CMS Pages.</p> 
<p>This will also increase registered users. You can customize the login Popup. 
Change Title
Write a brief description
Upload an image for the template
Enable the close button with custom text
</p>
<b><h3>Key Features</h3></b>
<ol>
<li>Set Force Logins for Users to Access Pages</li>
<li>Display Default Login or Custom Login Form</li>
<li>Enable Force Login on Specific Products, Categories & CMS Pages</li>
<li>Force Login on Checkout or Cart Page</li>
<li>Personalize Login Popup Template</li>
<li>Set Login Popup Appear Time in Seconds</li>
</ol>
<h4>More</h4>
<ul>
<li>45 days money back</li>
<li>FREE lifetime support</li>
<li>FREE lifetime upgrades</li>
<li>2 Minutes installation</li>
<li>Developed by Magento certified developers</li>
<li>Verified by Market Place</li>
<li>Easy to install</li>
<li>Responsive Design</li>
<li>100% Open Source </li>

</ul>
background color woocommerce element
Published: 2019-11-19 10:53:57

Hello. 

I am a beginner so please bare with my nooby questions..
I am making a woocommerce site and want to adjust some woocommerce elements. I want to change the background color of (which I find using the inspector) <div class="woocommerce-form-coupon-toggle">.

I then write in the wordpress css space --> 
.woocommerce-form-coupon-toggle {
    background-color: #000000 !important;
}

But nothing happens.. For your information, other css adjustments responds but not the background-color which is the only thing I want to change. 
Could anyone please guide me :)?
The Next Level of Data Visualization in Python
Published: 2019-11-19 10:31:16

The sunk-cost fallacy is one of many harmful cognitive biases to which humans fall prey. It refers to our tendency to continue to devote time and resources to a lost cause because we have already spent — sunk — so much time in the pursuit. The sunk-cost fallacy applies to stay in bad jobs longer than we should, slaving away at a project even when it’s clear it won’t work, and yes, continuing to use a tedious, outdated plotting library — matplotlib — when more efficient, interactive, and better-looking alternatives exist.

Over the past few months, I’ve realized the only reason I use matplotlib is the hundreds of hours I’ve sunk into learning the convoluted syntax. This complication leads to hours of frustration on StackOverflow figuring out how to format dates or add a second y-axis. Fortunately, this is a great time for Python plotting, and after exploring the options, a clear winner — in terms of ease-of-use, documentation, and functionality — is the plotly Python library.

#Plotly Brief Overview:
The plotly Python package is an open-source library built on plotly.js which in turn is built on d3.js. We’ll be using a wrapper on plotly called cufflinks designed to work with Pandas dataframes. So, our entire stack is cufflinks > plotly > plotly.js > d3.js which means we get the efficiency of coding in Python with the incredible interactive graphics capabilities of d3.

# #python #data_visualisation
VR App Development Services by Oodles Technologies
Tags: vr, ar, virtualreality, augmentedreality
Published: 2019-11-19 10:27:56

VR App Development and Consulting

We provide end-to-end AR VR app development services to strengthen your brand perception with increased user engagement and impactful advertising strategies. We use agile development methodologies and an advanced AI toolkit to build feature-rich VR apps that include the following

Virtual product environment
3D presentations and sales tools
VR Apps for E-commerce

 
VR App Design Services


 
We create interactive 3D app designs with smooth navigation and easy accessibility across devices. Our design team formulates effective UI UX design strategies to create app interfaces that provide a consistent brand experience

Custom themes and templates
Adaptability across screen sizes
Functional app prototypes
VR-App-Design-Services

VR App Integration and Migration

Our seasoned team of VR app developers integrates your app with third-party services and proprietary VR plugins to enhance its capabilities. We are also experienced in migrating your business app from its existing tech stack to a variety of web and mobile platforms

Cross-platform migration and integration
Improved app performance and efficiency
Quality Assurance and Testing


 
We perform routine system checkups and usability tests to identify bugs, software issues, and usability challenges. Our QA engineers test your VR app across a variety of performance metrics to significantly improve its performance across devices

Full-scale performance testing
Improved app performance
VR-App-Support-and-Maintenance

VR App Support and Maintenance

Our support and maintenance services ensure that your VR app performs at its peak efficiency with low latency. We optimize your VR app for handling peak load instances with minimal downtime

Round the clock app monitoring
Routine system checkup
Resolution of bugs and software issues
We provide 360-degree virtual reality app development services to build feature-rich VR apps that deliver immersive user experiences across supported devices. Our AR VR app developers use agile methodologies to develop 3D app interfaces that maximize user engagement with appealing visuals and graphics.
Visit: https://www.oodlestechnologies.com/virtual-reality-app-development-services/