8

I am currently writing lightning components and to do so I use Ecmascript2015 standard (Object.assign, const, let, ...).

Everything works perfectly but the https://www.npmjs.com/package/salesforce-lightning-cli is used to lint my code with the built-in rules and it gives errors when using const or let.

Will ES6 be fully supported in the future ? So I can leave those eslint issues unresolved. Or is it better to stay with es5 block-scope ?

1
  • ES5 with use strict would be what's wise to use for now.
    – crmprogdev
    Sep 26, 2016 at 13:20

1 Answer 1

4

It's safe to use ES6 constructs as long as you do not require Lightning to do any transpilation for you to support non ES6 compliant browsers

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .