Skip to content

Instantly share code, notes, and snippets.

View romidane's full-sized avatar

Steven Bapaga romidane

  • Swiftech Consulting Ltd
  • United Kingdom
View GitHub Profile
@romidane
romidane / destructuring.js
Created December 1, 2015 22:40 — forked from mikaelbr/destructuring.js
Several demos and usages for ES6 destructuring.
// === Arrays
var [a, b] = [1, 2];
console.log(a, b);
//=> 1 2
// Use from functions, only select from pattern
var foo = () => {
return [1, 2, 3];