Starter to ES6

Bashar Ayyash
2 min readAug 29, 2015

--

Go Back to Main Post

ES6 (EcmaScript 6 or Javascript 2015) it is the new javascript which will make developers life easier. ES6 is an update to the javascript we know.

I will show you how to test and view the results for ES6 code before diving deep into the details, below three ways to test ES6 code, two ways to test and see the result and the other to develop.

  • First way, this is the quickest and easiest way, go to http://www.es6fiddle.net/ start coding and see the result of the compiled code.
  • Second way, install Chrome extension ScratchJS after installing the extension go and inspect the developer tools for Chrome then select ScratchJS tab
In the left panel you can enter ES6 code and in the right panel you will see the output in old javascript (Ecmascript 5: the one we are using)
  • Third way, by installing babel (which is a transpiler to compile tomorrow’s code into today’s environment., explained in Starter Scripts Development Environment

git repository url: https://github.com/yabasha/starter-to-scripts

Diving into ES6 sea

1. New Way to Declare Variables

2. IIFE to Block

3. Iteration

3.1.1 Generators

4.1 Strings

4.2 Date

4.3 Number

5. Spread Operator

6. Arrow Function

7. Class

….writing

Go Back

--

--

Bashar Ayyash

Front End Developer, I’m confident that Vue.js is as powerful as React, but way more flexible and a lot easier to learn