Tutorials on Web Development, Programming, and Web Design

ES6 Modules Overview

In Tutorials

To learn about ES6 Modules, you have to have Node.js and the typescript compiler tsc installed as described in previous tutorial.  This is because at the time of this writing, browsers have not...

read more

Installing tsc Typescript Compiler

In Tutorials

To install the command line tsc Typescript Compiler using npm, you have to have Node and npm installed as described in previous tutorial. Then at terminal (in Mac) or Node.js command prompt in...

read more

Example of set in Javascript ES6

In Tutorials

Here is an example of iterating through the values of a set in ES6… Unlike Map, it can only contain unique values.  You add to a set using “add” instead of “set”....

read more

Example of Map in Javascript ES6

In Tutorials

With ES6, we have Map where we can store key value pairs using the “set” method… We get elements out using “get” method.  The map has a property of size to indicate...

read more

Example of for-of block in Javascript ES6

In Tutorials

While in previous tutorials, we used the forEach method to iterate through all the elements of an array; now we can use the for-of construct like this … And you get the results as...

read more

Example of class in Javascript ES6

In Tutorials

Here is an example of a class with constructor in Javascript ES6… The class name “Animal” is typically capitalized.  The instance variable “person” is not.  You...

read more

Destructuring in Javascript ES6

In Tutorials

Here we have an object “john” assigned to “employee”.   If we want to extract out the property value of “name” into a variable “n”.  And the property...

read more

const keyword in Javascript ES6

In Tutorials

The “const” keyword has the same block scope as the “let” keyword as shown in previous tutorial.  With const, whatever was assigned, can not be changed… Note that once...

read more

Arrow functions in Javascript ES6

In Tutorials

Continuing from the last tutorial, we changed the anonymous function in an arrow function like this… This is equivalent to use of anonymous function… but is much more concise. You drop...

read more

Learn Web Tutorials is hosted by Hostmonster and design based on Wordpress template by Elegant Themes
All contents are opinions and are copyrighted and may contain display ads and ad links for which site may receive revenues from.
See Terms of Use and Privacy Policy.