Você já deveria estar utilizando!
Essa palestra terá muito código.
1.
São os padrões, definições e funcionalidades que os browsers possibilitam para as nossas aplicações web.
Entidade responsável por votar e definir quais os padrões e novas funcionalidades
Adição das palavras reservadas let e const, para trabalhar melhor com o escopo de variáveis.
const PI = 3.141593
let event = "BH Tec Talks"
console.log(PI > 3.0);
PI = 2; //Uncaught TypeError: Assignment to constant variable.
function f() {
  {
    let x;
    {
      // okay, block scoped name
      const x = "sneaky";
      // error, const
      x = "foo";
    }
    // error, already declared in block
    let x = "inner";
  }
}Uma nova sintaxe para declaração de função.
let result = (a, b) => b*a;
console.log(result(10,2)); //20
const foo = () => 'bar'
const baz = (x) => {
  return x + 1
}
const squareSum = (...args) => {
  const squared = args.map(x => Math.pow(x, 2))
  return squared.reduce((prev, curr) => prev + curr)
}
this.items.map(x => this.doSomethingWith(x))let name = 'Yan';
console.log(`Olá ${name} tudo bem?`);let callMyName = (name="Yan",gretting="Hi ")
=> console.log(gretting,name);
callMyName(); // Hi YanUma forma mais fácil, amigável e OO Like de se criar classes e métodos.
class Cliente {
  constructor(nome, email) {
    this.nome = nome;
    this.email = email;
  }
  hello() {
    return `Olá ${this.nome} tudo bem?`
  }
  send() {
    return `Enviando email para ${this.email}...`
  }
}
let pessoa = new Cliente('Yan', 'email@email.com');
console.log(pessoa.hello());//Ola Yan tudo bem?
console.log(pessoa.send());//Enviando email para email@email.com
class Character{
    constructor(x,y){
    	this.x = x;
    	this.y = y;
    	this.health_ = 100;
    }
    damage(){
       this.health_ -= 10;
    }
    getHealth() {
      return this.health_;
    }
    toString() {
       return "x: " + this.x + " y: " + this.y 
       + " health: " + this.health_;
    }
}class Player extends Character{
   constructor(x,y,name){
      super(x,y);
      this.name = name;
   }
   move(dx, dy) {
    this.x += dx;
    this.y += dy;
   }
   toString(){
      return "name: " + this.name 
      + " " + super.toString();
   }
}
//Work
var x = 10
var y = 20
var name = 'Yan';
var character = new Character(x, y);
character.damage();
console.log(character.toString()); // x: 10 y: 20 health: 90
var player = new Player(x, y, name);
player.damage();
player.move(7, 8);
console.log(player.toString()); // name: Yan x: 17 y: 28 health: 90
Escrever os componentes do seu projeto, reaproveitamento de código e estruturas modulares.
/* solution-math file */
export const PI = 3.141592;
var _sqrt = function(s, x, last){
  return x != last 
  ? _sqrt(s, (x + s / x) / 2.0, x) : x;
};
export function sqrt(s){
  return _sqrt(s, s/2.0, 0.0);
};
export function square(x) {
  return x * x;
};
/* module.js file */
/**
* Utilizing the solution-math
**/
var arg1 = 2;
var arg2 = 3;
import {PI, sqrt, square} from './solution-math'; 
//Load all code of solution-math
console.log(PI);
console.log(sqrt(+arg1)); //Float Number
console.log(square(+arg2)); //Float Number 
Uma feature para executar rotinas de forma assíncrona. É uma representação de um valor que pode ser disponibilizado no futuro.
São utilizadas em muitas bibliotecas Javascript.
readFilePromisified('config.json')
.then(function (text) { // (A)
    const obj = JSON.parse(text);
    console.log(JSON.stringify(obj, null, 4));
})
.catch(function (error) { // (B)
    // File read error or JSON SyntaxError
    console.error('An error occurred', error);
});
function msgAfterTimeout (msg, who, timeout) {
    return new Promise((resolve, reject) => {
        setTimeout(() => resolve(`${msg} Hello ${who}!`), timeout)
    })
}
msgAfterTimeout("Gretting - ", "Yan", 100)
.then((msg) =>
    msgAfterTimeout(msg, "BH TEC", 200))
.then((msg) =>
    msgAfterTimeout(msg, "Talks", 400))
.then((msg) => {
    console.log(`done after 600ms:${msg}`)
})
// Sets
var s = new Set();
s.add("hello").add("goodbye").add("hello");
s.size === 2;
s.has("hello") === true;
// Maps
var m = new Map();
m.set("hello", 42);
m.set(s, 34);
m.get(s) == 34;
function f(x, ...y) {
  // y is an Array
  return x * y.length;
}
console.log(f(3, "hello", true) == 6); //trueconst arr = ['one!', 'two!', 'three!', 'four!']
const [one, two, ...rest] = arr
const obj = {a: 'x', b: 'y', c: 'z'}
const {a, b, c} = objconst foo = ['a', 'b', 'c']
const bar = ['d', 'e', 'f']
console.log(...foo)
console.log([...foo, ...bar])2.
class Foo {
  static bar = 'hello'
}
console.log(Foo.bar)class Cat {
  name = 'Tom'
  state = {
    running: true
  }
  constructor() {
    console.log(this.name, this.state.running)
  }
}
new Cat()const defaultStyle = {
  color: 'black',
  fontSize: 12,
  fontWeight: 'normal'
}
const style = {
  ...defaultStyle,
  fontWeight: 'bold',
  backgroundColor: 'white'
}
// Note that fontWeight is 'bold', as the second
// assignment overrode the initial assignment.
console.log(style)const fetchData = async () => {
  return fetch('https://randomuser.me/api/')
}
const printData = async () => {
  try {
    const data = await fetchData()
    const json = await data.json()
    console.log(json)
  } catch(e) {
    console.error("Problem", e)
  }
}
printData()/yanmagale
/yaanmagale
/yaanmagalhaes