Link Search Menu Expand Document

Use Arrow Functions to Write Concise Anonymous Functions

Summary

  • Inline functions can be created that don’t need to be called.
  • Inline functions use arrow functions syntax (=>).

Final Code

const magic = () => new Date();