In this exercise, you must find all the instances the function keyword and replace them with arrow functions. The starting file for this exercise is ex0.js
- So, that's my case for and against the arrow function.…I now want you to practice.…So, I want you to pop open EX0.…It's zero because I was too lazy…to go back and re-number stuff.…I inserted this…just before the workshop.…This EX0, big old hairy mess of foobar stuff here.…This is the file that you have,…so you can know that there's a whole bunch…of functions in here,…functions used in various different ways,…functions used as ifys,…functions used as function declarations,…functions used as function expressions that are returned,…functions used as callbacks…passed to a map or a set timeout.…
Some of them have a dot this reference in them.…Whole bunch of functions across this.…Your task with exercise zero,…go crazy with the arrow function.…Right?…Start rewriting all of your stuff using the arrow function,…and by the way, I didn't go over this…but the thing that people that love…the arrow function love to do…is they also love to avoid the curly braces at all cost.…So, let's say we had a function like this.…Let's say we had a function called foo…
This course was created by Frontend Masters. It was originally released on 01/10/2017. We're pleased to host this training in our library.
- The arrow function
- Arrow function variations
- Closures and explicit blocks
- Default values
- Using the gather and spread operators
- Dumping variables
- Concise properties and methods
- Symbols, iterators, and generators
- Optimizing codes for the reader
Skill Level Intermediate
1. Arrow Functions
2. Block Scope
3. Default Values and the Gather/Spread Operators
5. Template Strings
6. Symbols, Iterators, and Generators
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.