Using ES modules natively in Node.js

Using ES modules natively in @nodejs:  by @rauschma #ReactJS #Javascript

  • Tip: if you don’t switch on any of the unlockables (extra features), you’ll stay 100% compatible with native ES modules on Node.js.
  • The current plan is to make ES modules available by default in Node.js 10 LTS.
  • Node.js has to be able to detect whether a file contains a CJS module or an ES module.
  • You can read about the alternatives in a separate blog post.
  • More information on ES modules in Node.js and browsers:

Starting with version 8.5.0, Node.js supports ES modules natively, behind a command line option. Most of the credit for this new functionality goes to Bradley Farias.
This blog post explains the details.
Continue reading “Using ES modules natively in Node.js”

Why we moved from Angular 2 to Vue.js (and why we didn’t choose React)

  • My conclusion about Angular 2 was simple, the only thing Angular 1 and 2 share in common is the name, they are completely different frameworks.So consider that we had 17 versions to upgrade on a non-tested system, a lot of pressure from the business to write new features, lots of bugs and poorly written code, the original developers weren’t on the team anymore, only one developer (me) at the time with many other responsibilities, Typescript, problems with finding the right documentation since I was using a beta, and Angular 2 moving to version 4.
  • I got a good understanding of the basic concepts of Vue.js, defined a good and extendable architecture but most importantly I really enjoyed the experience of writing code with it and I felt I was doing it faster that with React.React was a lot harder than I thought, choosing between Redux and MobX is more problematic than having one option that is well integrated with the framework like Vue.js and Vuex do.
  • React took the most mentions and Angular 2 came in a distant second place.I started to look for local talent with Vue.js experience and I did find some who were really good so I started to think that I was not alone, my social techy circle was probably too small and I shouldn’t play enough attention to the fact that I didn’t know anyone in person working with Vue.js on production.MobileAt the time we were thinking about Vue.js vs React, we were also considering rewriting our mobile app and React Native looked like a really good choice.
  • Twitter is another good example, they released Bootstrap under the very permissive MIT License and no one is talking about License problems with Bootstrap.Final wordsOut of the many web pages I researched before making a decision, one graph caught my attention, the developer satisfaction on The state of Javascript survey that Sacha Greif @sachagreif does every year.
  • You can read The State of Javascript on the following link.Overall, Vue.js was the the winner in our evaluation, it had many questions answered on Stack Overflow, the clearest official documentation of the three options, the smallest code base, integrates well with Bootstrap and learning that it was backed by strong projects like Laravel and a big company like Alibaba was a big plus.

At Rever (www.reverscore.com) we just released a new version of our web client using Vue.js. 641 commits and 16 weeks of intense development after with two resources, here we are, very proud of a…
Continue reading “Why we moved from Angular 2 to Vue.js (and why we didn’t choose React)”

Why we moved from Angular 2 to Vue.js (and why we didn’t choose React)

  • My conclusion about Angular 2 was simple, the only thing Angular 1 and 2 share in common is the name, they are completely different frameworks.So consider that we had 17 versions to upgrade on a non-tested system, a lot of pressure from the business to write new features, lots of bugs and poorly written code, the original developers weren’t on the team anymore, only one developer (me) at the time with many other responsibilities, Typescript, problems with finding the right documentation since I was using a beta, and Angular 2 moving to version 4.
  • I got a good understanding of the basic concepts of Vue.js, defined a good and extendable architecture but most importantly I really enjoyed the experience of writing code with it and I felt I was doing it faster that with React.React was a lot harder than I thought, choosing between Redux and MobX is more problematic than having one option that is well integrated with the framework like Vue.js and Vuex do.
  • React took the most mentions and Angular 2 came in a distant second place.I started to look for local talent with Vue.js experience and I did find some who were really good so I started to think that I was not alone, my social techy circle was probably too small and I shouldn’t play enough attention to the fact that I didn’t know anyone in person working with Vue.js on production.MobileAt the time we were thinking about Vue.js vs React, we were also considering rewriting our mobile app and React Native looked like a really good choice.
  • Twitter is another good example, they released Bootstrap under the very permissive MIT License and no one is talking about License problems with Bootstrap.Final wordsOut of the many web pages I researched before making a decision, one graph caught my attention, the developer satisfaction on The state of Javascript survey that Sacha Greif @sachagreif does every year.
  • You can read The State of Javascript on the following link.Overall, Vue.js was the the winner in our evaluation, it had many questions answered on Stack Overflow, the clearest official documentation of the three options, the smallest code base, integrates well with Bootstrap and learning that it was backed by strong projects like Laravel and a big company like Alibaba was a big plus.

At Rever (www.reverscore.com) we just released a new version of our web client using Vue.js. 641 commits and 16 weeks of intense development after with two resources, here we are, very proud of a…
Continue reading “Why we moved from Angular 2 to Vue.js (and why we didn’t choose React)”

Array Methods Explained : Filter vs Map vs Reduce vs Foreach

  • we all know why this method is used for and even you don’t know about this method the name pretty much explains everything.Foreach takes a callback function and run that callback function on each element of array one by one.var sample = [1, 2, 3];// es5sample.forEach(function (elem, index){ console.log(elem + ‘ comes at ‘ + index);})// es6sample.forEach((elem, index) = `${elem} comes at ${index}`)/*output1 comes at 02 comes at 13 comes at 2*/For every element on the array we are calling a callback which gets element its index provided by foreach.Basically forEach works as a traditional for loop looping over the array and providing you array elements to do operations on them.okay!
  • If the value is true element remains in the resulting array but if the return value is false the element will be removed for the resulting array.var sample = [1, 2, 3] // yeah same array// es5var result = sample.filter(function(elem){ return elem !
  • As a ReactJS developer I use map a lot inside my application UI.Map like filter foreach takes a callback and run it against every element on the array but whats makes it unique is it generate a new array based on your existing array.Let’s understand map with an examplevar sample = [1, 2, 3] // i am never gonna change Boo!
  • Yeah// es5var mapped = sample.map(function(elem) { return elem * 10;})// es6let mapped = sample.map(elem = elem * 10)console.log(mapped);/* output */[10, 20, 30]Map ran through every element of the array, multiplied it to 10 and returned the element which will be going to store inside our resulting array.Like filter, map also returns an array.
  • ReduceAs the name already suggest reduce method of the array object is used to reduce the array to one single value.For example if you have to add all the elements of an array you can do something like this.var sample = [1, 2, 3] // here we meet again// es5var sum = sample.reduce(function(sum, elem){ return sum + elem;})// es6var sum = sample.reduce((sum, elem) = sum + elem)console.log(sum)reduce takes a callback ( like every function we talked about ).

Okay so yeah we know they are different they have different purpose and goals still we don’t bother to understand them. We use arrays. A lot of arrays. We use arrays to show search lists, items added…
Continue reading “Array Methods Explained : Filter vs Map vs Reduce vs Foreach”

React JS, Angular & Vue JS

  • There are lots of different frameworks like Angular, React or Vue, libraries and other packages (like webpack).
  • You’ll get an introduction into the three most important JavaScript frameworks (Angular, React.js and Vue.js) and you’ll also get a detailed comparison!
  • This will then allow you to pick other resources or courses to dive super-deep into your chosen framework whilst having a solid foundation already.
  • Throughout the course, we’ll dive into the basics of these frameworks but we’ll also have a look at why we use them to begin with.
  • Not only are we going to dive into the basics of the three most popular JavaScript frameworks, this course will also draw a detailed comparison.

Angular (Angular 2 or 4), React or Vue? Get a Crash Course on each of them and a detailed comparison!
Continue reading “React JS, Angular & Vue JS”

ReactJS vs AngularJS 2 ultimate performance research 2017

#ReactJS vs. #AngularJS: Two sides of #JavaScript

  • Note: Among all the Angular 2 features, the availability of MVC pattern out-of-the-box is a significant advantage over React.
  • Having really straightforward UI for your data, Angular allows you to get the end result with the more intuitive approach to the user interface that demands less code and seems to be more ‘obvious’.
  • However, starting from the second version, Angular developers have fixed that issue transferring its rendering model to the server side.
  • As you know, Angular creates a watcher for every binding in order to track all the changes in DOM.
  • We had a little meeting related to React vs Angular question during which our front-end developers had an opportunity to discuss all the pros and cons of these technologies.

These frameworks take top places in our commercial projects. This month, we analyzed their performance and prepared a guideline for web developers in 2017 aimed to help in solving React vs Angular battle.
Continue reading “ReactJS vs AngularJS 2 ultimate performance research 2017”