JavaScript Decorators: @time




In this video, we build a JavaScript decorator that will time how long a function takes to run.

Links:

– Exploring EcmaScript Decorators: https://medium.com/google-developers/exploring-es7-decorators-76ecb65fb841
– JSFiddle Code: https://jsfiddle.net/andrew8088/cfd5h39n/

Original source


16 responses to “JavaScript Decorators: @time”

  1. When i try this on jsfiddle i get an error in the console saying ''You are using the in-browser Babel transformer. Be sure to precompile your scripts for production.'''
    How on earth can i play with decorators online?

Leave a Reply