ECMAScript 2016: New Version of JavaScript Language Released (softpedia.com)
An anonymous Slashdot reader writes: Ecma International, the organization in charge of managing the ECMAScript standard, has published the most recent version of the JavaScript language. ECMAScript 2016 (ES7 or JavaScript 7th Edition in the old naming scheme) comes with very few new features. The most important is that JavaScript developers will finally get a "raise to the power" operator, which was mysteriously left out of the standard for 20 years. The operator is **...
It will also become much easier to search for data in a JavaScript array with Array.prototype.includes(), but support for async functions (initially announced for ES2016), has been deferred until next year's release. "From now on, expect smaller changelogs from the ECMAScript team," reports Softpedia, "since this was the plan set out last year. Fewer breaking changes means more time to migrate code, instead of having to rewrite entire applications, as developers did when the mammoth ES6 release came out last year."
It will also become much easier to search for data in a JavaScript array with Array.prototype.includes(), but support for async functions (initially announced for ES2016), has been deferred until next year's release. "From now on, expect smaller changelogs from the ECMAScript team," reports Softpedia, "since this was the plan set out last year. Fewer breaking changes means more time to migrate code, instead of having to rewrite entire applications, as developers did when the mammoth ES6 release came out last year."
lots of knowledgeable people hate or dislike javascript, and have done so from the start, and give excellent reasons for their hate and dislike.
but it has succeeded in spite of them and these reasons, and is more or less an indispensable part of modern on-line world currently.
why? what did these 'knowledgeable' people missed or still miss when evaluating it?
The power operator will get used once by one guy, who will use it in this code:
export function pow(base, exponent) {return base**exponent;}
To use it, enter this command:
npm install js-power
Then, in your code:
const power = require('js-power');
let eight = power.pow(2, 3);
It's just that easy!
Just don't expect me to enable it in my browser for 99.9% of web sites.
Because that would be idiotic.
Some background on async functions: http://www.infoworld.com/artic... To be fair, it was a mammoth endeavor to add proper async support in just a few months.
Very surprised that we've already moved to ES7, especially considering how much ES6 changed.
Changes are really minor. Can now write a**b instead of Math.pow(a,b) or ar.includes(x) instead of ar.indexOf(x)>=0. Nice, but I'll still use the old methods if just for compatibility's sake.
The only way JavaScript can be considered a "success" is if you define "success" to mean "used because it's the only option available".
But aside from that very limited view of "success", JavaScript is a total disaster.
It's a very broken language. Its type system is a wreck. It didn't have real class OO for ages, and even its prototype approach is shitty compared to Self. Its standard library is rubbish. Its syntax is mediocre. It is full of utterly stupid shit like semicolon insertion. It's a failure when looked at solely as a programming language.
Its surrounding ecosystem is also very broken. Numerous companies and organizations have had to pour huge amounts of money and other resources into it just to get JavaScript implementations that don't limp along at a snail's pace. It has also given us clusterfucks like Node.js and npm. Building anything more than an onclick handler using JavaScript rapidly becomes a huge debacle, and a maintenance headache.
Its community is among the worst there is. Something has to be pretty wrong with a community that thinks a language as awful and broken as JavaScript is worth celebrating! But I will give the JavaScript community credit, it isn't as terrible as the Rust community is. At least the JavaScript community's biggest offense is only ignorance. They aren't hypocrites who attack others with their tyrannical Code of Conduct, like we see some other programming language communities do.
JavaScript just isn't a success in any reasonable sense. It's a failure.
We all expect 2^16 to return 65,536. Why make it something different?
Now with native fag support
In a few more years we'll have this turd polished to a mirror sheen! Maybe some day enough of the horrible design flaws will be undone and make it almost halfway comparable to a serious language.
When somebody makes this "argument", it's a sure sign that they've never actually used Python, and that they're just spewing bullshit.
Anyone who has used Python knows that this is totally a non issue. PEP 8 explains very clearly how to avoid and any all problems: "Use 4 spaces per indentation level."
That's all you have to do! Like it says, use 4 spaces per indentation level. It's as simple as that.
When somebody makes this "argument", it's also a sure sign that they've never actually used Python, and that they're just spewing bullshit.
Python has remarkably good backwards compatibility. A number of Python 3 features were actually backported to Python 2. And Python 2 still sees excellent continued support. Python 2.7.11 was released only about 7 months ago, just two days before the latest Python 3 release, 3.5.1!
Anyone who wants to keep using Python 2 can continue to do so. Those who want to use Python 3 are able to do so, too. And there's the excellent "2to3" tool which can quickly and reliably convert nearly all Python 2 code to Python 3 code. Hell, there are many Python libraries that support both Python 2 and 3 with ease!
I'm sorry, son, but you clearly don't know what the fuck you're talking about.
JavaScript is has been the language all browsers support, but why? Also why is it so bad? The answer to both questions is the same:
Because it was created in ten days. While Microsoft was scheduling meetings to discuss a proposal to plan a browser language, Brendan Eich created JavaScript (then called Mocha) and released it to the public. It was used because it was available, while other options were draft proposals, not yet approved for development, much less ready to use.
When you spend all of two days designing a language and seven days implementing it, you end up with a pretty crappy language.
The opposite end of the spectrum is Perl 6, which was designed from 2004 to roughly 2015. It's a rather nice language, for those who like Perl-like languages.
"ECMA"Script? I would love to adopt it, but I want my web site to be accessible from the UK.
Can somebody please mod down the parent? It's totally full of bullshit.
The funniest part of this bullshit claim is that whatever you've supposedly done using Python, well, it likely depends on and uses the C and Python code I've contributed to the CPython implementation over the years! Son, you're out of your league.
You're the one who is out of touch, clearly. We serve compressed content these days, which actually is more effective than JavaScript hacks like minifcation. If you want to obfuscate your Python code, there are numerous products out there that will do that. Or Python's bytecode could potentially be served up instead, were the browsers ever to support Python for client-side scripting.
Son, you have no idea what you're talking about. You've demonstrated that repeatedly.
I was very much looking forward to await/async as a more mature way to natively provide clean synchronous wrappers for async code within synchronous code (and get around the nested hell of when/then). Please correct me if I'm wrong, but it only seems to be a future reserved word.
Right now, it appears I am still awaiting.
One reason ECMA can be so slow to release new features, is that they have no competition. If you want to write Web-based applications, you're stuck with JavaScript. There are no other viable options. Why should they be in a hurry to change things?
This is about to change. WebAssembly is coming. This is the development that will finally blow open the language barriers for browser-based programming. You'll be able to write client-side code in just about any language you already use and like, and you won't have to require the user to install some add-in to use it. Once this happens, it's quite possible that JavaScript will soon go the way of BASIC and COBOL.
Lots of knowledgeable people hate or dislike cockroaches. But cockroaches have succeeded in spite of them. What did these "knowledgeable" people miss when evaluating cockroaches?
Lots of knowledgeable people hate or dislike Donald Trump. But Donald Trump has succeeded in spite of them. What did these "knowledgeable" people miss when evaluating Donald Trump?
Generally speaking, when people decide they hate or dislike something, they are speaking for themselves. You can dislike cockroaches even if you're aware of their reproductive success, and you can dislike Donald Trump even if you're aware that he appeals to a lot of voters. Disliking something is not the same as predicting that it will go away of its own accord.
We all agree we hate Javascript. So why aren't there any alternative scripting languages in the browser yet?
Yeah, you have to wait, that is ES7.
Democracy Now! - your daily, uncensored, corporate-free
1. Rise of Web
2. Browser as a platform
lol fuckn hil;arious
Kill JS and put python in the browser: http://www.brython.info/