Hacker News new | ask | show | jobs
by pspeter3 3253 days ago
Not all browsers support ES2015 so knowing ES5 first is helpful.
2 comments

All current browsers support ES2017.

If supporting IE or out of date mobile devices is worth your time (it might be, it might not be - consider CSS grid won't work, flexbox won't work, webcrypto won't work, HTML5 clipboard won't work, and you'll need double the time to deal with them and their awful devtools) transpiling is a good option.

Except on almost any serious project you should be using a transpiler anyways.
Agreed, but I find it helpful to understand the transpiled code. The "clean" ES5 output was a large reason for using TypeScript https://blog.asana.com/2014/11/asana-switching-typescript/
I agree to an extent, but any modern transpired should also emit source maps which should shield most people from needing to look st or understand the "low level" generated code.
transpiler?
It converts your ES6 code into Javascript that can run on all browsers. It's how you can get advanced Javascript features before the browsers fully implement them. Look up Babel.
Converts modern JavaScript to ES5
It is a portmanteau of translater + compiler