4 ms·
I've been writing most of my Javascript in ES6 recently and I agree that it's simply fantastic and still has a lot of potential to be explored when it comes to
by error54 12y ago
I've been writing most of my Javascript in ES6 recently and I agree that it's simply fantastic and still has a lot of potential to be explored when it comes to creating modern apps and frameworks. My main problem is that we're going to be stuck using transpilers for quite a while as by the time all of the browsers finally[1] catch up to ES6, ES7 will be released. Unfortunately, there's not much we can do about slow vendors.
1 - http://kangax.github.io/compat-table/es6/ http://kangax.github.io/compat-table/es6/ (Note: Opera, Safari, and iOS8)
- deleted 12y ago[deleted]
- thomasfoster96 12y agoI wouldn't be quite so pessimistic. ES6 isn't finished yet- and I'd say it would be expected for some vendors to take another 6-12 months to add all new features after a finished spec is published. This is pretty much what happened with ES5, right?
- aikah 12y ago> and I'd say it would be expected for some vendors to take another 6-12 months to add all new features after a finished spec is published. And what happens with browsers on older mobile phones that cant be upgraded ? you let your scripts stop working ? If you think you can switch to ES6 in 6 month without any kind of transpilation, while keeping a good browser compatibility good luck ... > This is pretty much what happened with ES5, right? No,5 years after the launch of ES5 some browsers like Safari still didn't support some ES5 features. And some browsers on handsets will never support ES6.
- thomasfoster96 12y ago6-12 months was a bit optimistic (I thought ES5 was released in 2011, in fact ES5 was released in 2009 and ES5.1 in 2001) for vendor adoption I'll admit. Still, I can't imagine waiting more than 2-2.5 years for perhaps 80-90% of browsers supporting virtually all of ES6. > And what happens with browsers on older mobile phones that cant be upgraded ? you let your scripts stop working ? If I was absolutely worried about browser support on older mobile phones, I'd be still writing vanilla JavaScript with no features that aren't in Ecmascript 3. You'll have to drop support eventually. Plus, it's very likely a good chunk of the ES6 I'll be writing will only ever be intended for running in browsers that support other cutting-edge features like WebGL, Web Workers and WebRTC, or on a fairly up to date environment like iojs or node.js. > No,5 years after the launch of ES5 some browsers like Safari still didn't support some ES5 features. I'm not sure which features Safari is missing that you're referring to. Safari on both iOS and OS X are missing a lot of Javascript APIs, but both have fully supported ES5 since at least 2011 [0], and my old Macbook with Safari 5.1 has no problems running modern websites. > If you think you can switch to ES6 in 6 month without any kind of transpilation, while keeping a good browser compatibility good luck ... A lot of ES6 features are already being polyfilled (Typed Arrays have been polyfilled for years), plus you can use try/catch to support new syntax whilst also supplying some sort of fallback. [0] http://kangax.github.io/compat-table/es5/ http://kangax.github.io/compat-table/es5/
- pornel 12y agoCurrent versions of Opera use V8, so it's lagging behind as much as Chrome.