ES6 Tips of the Day
Last week I started publishing the “ES6 Tip of the Day” on twitter. We’ll see if it catches on. Nonetheless, I thought it would be nice to put them all out here in one blog post:
- In arrow functions => “this” retains it’s lexical scope.
- const does not create immutable arrays or objects. Only the references are immutable
- Enhanced object literals allow you to name members and methods at run time using computed property keys
- Use ` and string interpolation to create Template Literals instead of concatenating strings
Follow me on Twitter ignoreintuition if you dig this kind of thing and let me know if this is something that you would like me to continue in the comments.