Hacker News new | ask | show | jobs
JavaScript has beguiled the current generation of software developers (medium.com)
44 points by wodahs02 3705 days ago
25 comments

When I see the term "no self-respecting" developer, I know the article is going to be highly opinionated and complaint oriented with very little new information to discuss. I continue to be proved correct with this article.
To be fair, the OP is basically an intro to his post on how to "fix" javascript.[1] This post basically says we should create a new Javascript that is the same as the old Javascript without all the bad parts.

Which throws away the two biggest strengths of Javascript: it works everywhere, and is compatible with tons of existing code.

1: https://medium.com/javascript-non-grata/javascript-the-next-...

> create a new Javascript that is the same as the old JavaScript > without all the bad parts

Google tried this with Dart and failed.

While he has a point to a certain extent, it's also coming from a fairly purist POV. I respect that for diversity of opinion.
Reminds me of the opinion unix purists held towards Linux in the 90s.
I had to check to see if the article was dated April 1.

JS is both a compiler target and a language itself. WebAssembly enhances the runtime as a compiler target.

JS is also moving very fast, as evidenced by Babel. There are some big, bold ideas being explored in React, Angular, Om, elm, clojurescript, etc. I hesitate to take seriously anyone who thinks this is a bad thing, just as I hesitate to take seriously anyone who is a strong supporter of a major political party.

We simply don't need a single point of authority telling us the best way to do things, even if they are soon obsoleted, competition and sharing of ideas is good. I've learned a lot by exploring all of the frameworks he mentioned. Recently the Ember and React teams have been collaborating extensively, and I can't wait to see all that comes out of it (notably with respect to styling components).

The most embarrassing assertion the author makes is that CS curricula teach "programming languages". It teaches a way of thinking, and it really doesn't matter much which language is used as long as the basic principles are covered. JS might make a good language to look at when studying language design tradeoffs, since in some ways it falls short but has also become the dominant language when measured in terms of the number of runtimes in use in the world at any given moment.

So while the author does seem to wish to be constructive (he links to a vague proposal) the article is just clickbait and really shouldn't be taken seriously. If you are a new programmer reading the article and feeling discouraged, don't lose heart. Build stuff and you'll learn. Eventually try some other languages if all you've tried is JS, but don't listen to the nonsense in the article.

> It teaches a way of thinking, and it really doesn't matter much which language is used as long as the basic principles are covered.

Nevertheless, schools do not want to teach an inferior language that encourages bad programming habits. They (now) tend to rely on languages with a vocational bent, such as Python and Java. I remember my days in university when odd languages like Scheme and Turing were taught. Now, it's sensible to at least try to prepare the student for the job market. I'm glad they didn't stoop to JavaScript.

> If you are a new programmer reading the article and feeling discouraged, don't lose heart. Build stuff and you'll learn.

Why should a new programmer feel discouraged? There are plenty of good languages to choose from (Java, C#, Python, C++, Ruby, etc.). They offer varying levels of ease, but Python and Ruby would be more than good enough. If you want to do web development, use a transpiled language (). That'll save you much of the grief of JavaScript. (My personal favourite is Amber Smalltalk.)

I agree, build stuff and learn.

> There are some big, bold ideas being explored in React, Angular, Om, elm, clojurescript, etc.

I'm glad you mentioned ClojureScript. I didn't successfully add this link to my previous comment because ycombinator had a hiccup, but I recommend using transpiled languages instead of JS: https://medium.com/javascript-non-grata/the-super-surrogates...

Languages like Amber, Brython, ClojureScript, Dart, Haxe and Scala.js are great alternatives to using JS.

JavaScript, for better or for worse, like it or not, is here to stay. There is a ton of resources, by a huge community, and large corporations being thrown at improving it. This author needs to get off his high horse.
He doesn't disagree with that. Just that JavaScript's niche is frontend. And even that may be threatened with the advent of webassembly.
Not sure about the "niche" aspect of your comment, but Node is huge. The ability for a developer to work in the same language on both sides has been massive. The author is complaining that there is just too much JavaScript work out there. Someone must think it's pretty valuable. Let's face it, if you're not doing basically everything on the web at this point, you're not doing much, and that's where JavaScript reigns supreme.
Meanwhile Node is killing it on the backend.

Sorry, but this author is just the equivalent of an old man yelling at kids to get off his lawn... but worse, it's not even his lawn, never was, and the "kids" are the ones who built his home over the last 15 years.

He looks out of date, out of touch, and unwilling to develop skills and knowledge.

Not a good look.

Did you read the article? He considers and rejects that argument.
Did you?

"Node has been ... relegated to a web niche. ERP solutions ... aren’t using Node... don’t expect any serious shop to be washing their ... data through JS code...Fortune 500 shops aren’t basing their businesses on JavaScript ... JavaScript is intrinsically a dysfunctional language.... more flaws than any other programming language... JavaScript is wholly unsuitable for serious software... tens of thousands of lines of code ...difficult to ensure a specific level of quality..."

He's just ranting around. Even the "sources" are just scattered links to other rants of him...

He rejects it, but poorly and badly thought through - like most of the rest of his reasoning in the article
Node isn't "killing it" anywhere, as far as I can see. It's a special-case technology being touted as competition for proper server-side languages, but in reality it is poorly-suited for the job.

There's no valid reason why most people should choose JS on the server instead of Ruby, Python, PHP, C# or Java, except that so many people know JS and so many people love shiny "cool" stuff. Node is a deeply flawed and very messy ecosystem.

Verdict: no, but thanks.

> There's no valid reason why most people should choose JS on the server instead of Ruby, Python, PHP, C# or Java

It's faster than the first 3 of those and easier to write than the last 2. It handles concurrency better than the first 3 as well.

I'll be sure to let Ebay, Paypal, Yahoo, Walmart, AirBnB, Netflix, Uber.. etc that they are clearly wrong: because you said so.

I listed some reasonable questions just above this post, and I still don't have a good answer from anyone: what's the current list of apps these companies are running on Node, how special-case are they, how happy are these companies with their Node apps, how big a portion of their code bases are Node, etc?

I've seen some links to a few articles that date back 3-5 years, but nothing more current, and nothing very detailed at all. That list of companies you typed out is the same list of companies everybody always types out. I'm wondering about some actual details. I don't think that's unfair.

Downvoted since clearly hyperbole with 15 years timeframe.
13 years. It started in ~2003 that JavaScript as a whole was being approached differently. By 2006 a LOT had changed.

In 2008 V8 was released and 2009 Node was released. But that is merely the newest epoch of the current wave.

JavaScript has been taken seriously by those paying attention for ~13 years. They've been building the web with it while others complain about it.

So sorry, I rounded up by 2 years. But hyperbolic? Not really.

For server side javascript the earliest vague reference I can think of is Steve Yegge, - "The Next Big Language" from 2007: http://steve-yegge.blogspot.com/2007/02/next-big-language.ht...

You seriously mean something was brewing 4 years before that?

The author makes two decent points:

1. Javascript popularity is tied to web popularity

2. Web popularity is shrinking

But he makes it in such a histrionic way that it's hard to focus on that over his bombast.

You can sound the alarms over almost any language if you want too, it's fun but hardly informative.

Java - only for companies that don't want to be agile

Python - Great for hacking on the weekends, but no killer use case

Ruby - Only has Rails, and the web is shrinking

Haskell/Scala/Whatever - Never gonna break out of a university

These are well worn arguments that don't really capture that jobs and companies tech stacks are much more nuanced than these simple statements. If you care about code, you'll find work, no matter what language beguiled you first. If anything, Javascript hasn't beguiled a generation of developers, the web has. And if we move on from the web, we'll move on from JS, and as long as we care about what's next, we'll thrive.

The author also ignores what I consider to be Javascript's strongest trait: It works everywhere and does everything. Shipping JS with every browser means there is no barrier for entry.

Sure the syntax is pretty meh, the community is disorganized, performance is OK, and there are a lot of poorly written libraries out there... but it's downright amazing how much surface Javascript+Browser covers. WebGL, WebVR, WebCL, WebRTC, hell even just the out-of-the-box cross-platform UI. Install Node and you get access to all the systems stuff as well.

It's my job to write Ruby and I love the language. I also really enjoyed C++ and Python... but Javascript is now my go-to language outside of work. It's amazing, it's like it was made for hacking.

1. The JavaScript ecosystem is open

2. JavaScript does about everything

3. There are many JavaScript developers

1. and 2. are enough for me and 3. is enough for most companies.

JS is the next stage of the Web after PHP

For all the text the author wrote about how bad JavaScript is, I had to click through two links to find any actual substantive complaints about JS, which were (1) JS doesn't have an array type; (2) JS doesn't have an integer type. (1) seems false to me (extra false if you count Typed Arrays), and (2) is being worked on in the committee.

(I think JS has a lot of flaws, but it's not as bad as its reputation suggests.)

Not to mention the "Number as Double" issue has been called a massive mistake by most people involved in writing the standards.

However it's not a simple issue to change it at this point, but people ARE aware.

I think in time, we will look back at the mess of "modern js" development, including the true shit-show of npm, in the same way we look back at the horrors of J2EE, XML hell, bean hell, FactoryOfFactoryOfFactoryofEclipsePleaseAutoCompleteThisBeforeRSIsetsIn, and the rest.

The only interesting bit is whether it will be webassembly or something else that actually drags us into a paradigm shift for the web.

Everything will always be horrible. I promise.
JavaEE is not horrible.

It is rock solid, has a nice and friendly community, tons of resources, several high-quality open source implementations and the Java language itself has 2 or 3 IDEs in the top 10 IDEs list (ok, the last one is my subjective opinion.)

>The only interesting bit is whether it will be webassembly or something else

I'm interested in this as well. The near term plans, though, don't give wasm languages dom access, and limits wasm to statically typed languages. So, it's basically relegated to being an ffi layer for js for quite some time. I don't see that changing the world much.

Shit show? It's a dependency manager. It's no different to any other dependency manager, like RPM or dpkg. It has way more stuff in it's repos than any previous dependency manager, which is good, because programmers don't have to constantly rewrite the wheel. I hope for something like that has the scale of npm on other languages in future.
Npm is awesome. When I want poorly thought out single line functions disguised as modules, with dependency chains a mile long, is it my go-to tool.

After all, why have a simple left-pad function, when I have lots and lots of modules, just to achieve the same result?

A simple left pad function is a module. One is simply a container for the other. It honestly sounds like you haven't used npm.
> JavaScript is intrinsically a dysfunctional language. It has many more flaws than any other programming language in wide use. JavaScript is wholly unsuitable for serious software engineering, esp. at scale. When your application grows to tens of thousands of lines of code, it becomes much more difficult to maintain, much more difficult to ensure a specific level of quality.

Replace Javascript with PHP and you get the usual complaint people have about PHP (but there's still Facebook). Replace a few words and Javascript with Java and you get another common complaint, still, all these languages are in active use at various companies, so maybe they have their uses?

There are two kinds of programming languages: The ones people complain about and the ones no one uses.
Worse still - it exposes that he really doesn't know that much about JavaScript development at scale.

Dunning-Kruger in action.

NASA, PayPal, Uber, Facebook, Yahoo, Fitbit, Intuit are all using Node.js...guess they're all just niche too?
Isn't everyone "using" everything? Unless a large percentage of the code the company is currently using is in a language, I don't consider the company to be "using" the language.
So nobody's really using anything unless they use it exclusively? I guess nobody's using anything then. Google isn't using Go. Microsoft isn't using C#.
A significant amount of the code in many of those companies is Node - especially in non-legacy code.

Your comment ignores legacy code bases, which are common at large companies, in favor of an unrealistic yard stick.

Clearly, Node is widely used. It would be silly to deny that. The real question is to what extent is it being used, i.e., is it used to write large, mission-critical systems, is it used beyond developing client-facing web applications (which tend not to be very big), is it used company-wide in lieu of previous language infrastructures such as Java, C#, Python and C++? Now, that would be impressive.
This is a poorly written opinion piece from someone who isn't a JavaScript developer. Most arguments he makes have no facts to back them up. Many of his claims are made from a position of obvious ignorance: many Fortune 500 companies do in fact use JavaScript, and an incredible number of startups do. To claim otherwise is just ridiculous. He claims that games could never use JS and yet WebGL has already given us this.

So what industry-favourite, startup-embraced, wildly popular language does this author advocate?

Smalltalk.

Seriously?

So who's making arguments without supporting facts? The Hacker Life provides evidence that startups prefer Ruby, C and Python. Fortune 500 companies may use JS for client-facing web UI applications (which are generally not mission-critical), but for heavy-duty shit, they'll stick to Java, C#, Python, C++, etc. Show me what Fortune 500 companies are replacing these tried-and-true workhorses with JavaScript.

As for games, what serious gaming platform relies on WebGL? Most games are written in C++ for a reason: maximum performance. When I was Project Team Leader of the Windows NT Driver Group at ATI Technologies (now AMD), all the OpenGL software I saw was written in C++. JavaScript could never have been usable, even with V8.

Smalltalk, seriously. It's still used today around the world by many businesses. Cincom and GemTalk are major Smalltalk vendors. I have friends working at Cherniak Software and Simberon, both important Smalltalk software houses. ESUG (European Smalltalk User Group) is a mammoth organization representing hundreds of companies using Smalltalk. What did you say about "a position of obvious ignorance?"

> This is a poorly written opinion piece from someone who isn't a JavaScript developer.

I've written serious things in JS (ok, ECMA Script) back before a lot of people around here started coding it seems. Back when IE ruled the web and SVG was an Adobe plugin to IE.

And I say this post isn't too bad.

"On the server side, we’ve seen Node.js gain traction for “back end” applications. But Node has been pretty much relegated to a web niche. ERP solutions like SAP aren’t using Node. While a company may use JS for their website, don’t expect any serious shop to be washing their critical Business Intelligence data through JS code. The truth is, most Fortune 500 shops aren’t basing their businesses on JavaScript and never will."

Next time you make such a bold claim, maybe Google it for a few seconds ;-) Legacy SAP stuff predates Javascript. Modern SAP stuff is different, "HANA Extended Application Services" is actually a server-side Javascript runtime. What is HANA made for? Exactly, "critical Business Intelligence data" ;-)

http://scn.sap.com/community/developer-center/hana/blog/2015...

http://help.sap.com/hana/SAP_HANA_Developer_Guide_for_SAP_HA...

Interesting, but it remains to be seen how many businesses will actually use HANA. Until you can identify what percentage of Fortune 500 will use HANA XS with Node, I stand by my statement.
If you're wondering whether or not to take this with a grain of salt, please note the author has a section of his blog devoted to explaining why javascript is apparently bad.

https://medium.com/javascript-non-grata

My initial reaction to this was “Why would anyone have such strong feelings against any particular programming language?” Then I remembered how I feel about Java.

(I’m obviously joking here. I’m not 15 anymore. If you pay me to build your house with that particular hammer, fine.)

Headline is intentionally awful. tl;dr: the "lie" is that javascript is a bad language, and developers should not learn it.

Proceed if you enjoy programming language screeds, this one makes few technical points and focused on the argument that learning JS is not a practical professional decision.

The article is worse, it suggests that the Javascript language itself is what has doing the lying. Not people, the language. Keep that in mind.
> Even Redmonk’s language ranking is deceptive. JavaScript is on top because of the massive number of lines of code committed to Github. What are we to make of this? Well, JS is the native language of the web browser; if you want to write a browser application, you have no choice (for now). Redmonk is effectively saying that the web is popular, not that JavaScript is popular. Duh!

I'd probably also add that a lot of that is probably copies of popular libraries just getting checked into people's projects implemented primarily in other languages.

I'm more excited about SPAs and other stuff happening in the browser than this guy is but I don't really get the JS outside of the browser hype.

I find this hard to swallow as somebody that works with JavaScript on a daily basis both as a backend and front-end technology.

For one thing, it's an intellectually interesting space to be in and for another, there is so much of the open source community working in this space, it just simply allows me to stand on the shoulders of giants and deliver.

Checkout http://githut.info/ and, yes npm.

I recognise there are failings in JavaScript and that is why I've switched to TypeScript and now transpile to JavaScript.

Do I think there are problems with JavaScript? Of course there are, but does it make it a bad language? No.

> The truth is, most Fortune 500 shops aren’t basing their businesses on JavaScript and never will

I'm not sure what the author means by "basing their businesses on JavaScript" but lots of Fortune 500 companies are using the SPA frameworks he decried. Facebook (Fortune 500) - not only uses - but invented React, Google invented Angular, and the Fortune 500 company I work for has Angular applications in production.

Maybe the author meant "No Fortune 500 company is putting all their eggs in one basket," but that's just tech in general.

Many enterprises are, indeed, using SPA and Node...for the client-facing, non-mission-critical web UI software. These applications tend not to be very large, and on this scale, these tools are usable. But once you get to the really heavy stuff that enterprises rest their critical core business on, they'll stick with real languages like Java, C#, Python, C++ and Scala...things that they trust without question.
No big corporations are building their apps on Node, I think was his point. And he's right.
Walmart must be considered a small corporation then. Good to know.
Help us out, those of us who remain unenlightened:

1.which app(s) did Walmart build with nothing but Node on the back end?

2.How has it worked out? Are they happy with that software?

3. Any internal plans to rebuild with something else, or are they going to use Node in even more places in the near future?

Honest questions.

A good place to start is this quora link[1] that has many further links to read.

[1]https://www.quora.com/What-are-the-biggest-websites-built-wi...

That Quora post perfectly illustrates my confusion with all the claims about Node: every example of Node usage there is 3 to 5 years old, as far as I can tell.

I'm really interested in what large-scale production apps, commercial or in-house enterprise, are currently using Node on the server? For sure, not just misinterpretation and wishful thinking?

A while back, the frontpage of the Node website had a list of all the companies using Node. Microsoft was one of them
Good point, and I've seen this stuff referenced before, so perhaps my comment above is a little over-stated.

But my confusion remains: how big are all these Node apps, what are they being used for, how robust have they proven to be, how happy are these companies with their Node server side code, how far will these Node apps be extended, how much more Node will these companies be implementing, etc.

My skepticism is fueled, in part, by numerous incidents like the one recently on the Atlanta JavaScript Slack channel, where a Node Evangelist was telling everyone how WordPress had rebuilt their infrastructure in Node. Problem is, WordPress has done nothing of the sort. They actually built a small downloadable app for WordPress admins to use in managing their WordPress sites, as far as I could figure out. Which is precisely what Node MIGHT be considered good for, no doubt about it.

But that's not what our Node Evangelist friend was preaching. And I just get the feeling that a lot of people who are spreading the Node Word are misunderstanding some of the facts on the ground. There might be some wishful thinking in Node Land. Because I wouldn't choose Node over any of 6 other server side languages right now, and I sure wouldn't attempt to build robust apps for our clients on such a fragmented and messy ecosystem of modules and shiny fads.

On that note,, where's the Django or Rails or .NET or Spring of Node Land? I can't seem to find it, and without it, Node is a non-starter for so many professionals. Just seems obvious, but maybe I'm wrong.

> Good point, and I've seen this stuff referenced before, so perhaps my comment above is a little over-stated.

No worries. My main criticism is that the author's position (that big companies aren't relying on JS) was over-stated (or vacuously true, if we're being charitable).

> And I just get the feeling that a lot of people who are spreading the Node Word are misunderstanding some of the facts on the ground.

That wouldn't surprise me

> On that note,, where's the Django or Rails or .NET or Spring of Node Land?

I don't know much about ReactJS, but it's my understanding that you can switch between client-side and server-side templating in a way that's transparent to the developer. That's probably the closest thing you'll find to Spring.

There's also Jade (http://jade-lang.com/), but that's not a framework.

Basically a big rant about javascript.

I do agree, at a high level, that the litany of frameworks, and which ones to use together...is a barrier right now.

It's somewhat amusing to compare the effort required to make a relatively simple "SPA", versus doing the same thing in a "fat client" via C#, Java/Swing, or similar.

But, it's a relatively new ecosystem. I'm sure the dust will settle sooner or later, and a reasonable end-to-end solution will emerge.

> a wild wild West of free-for-alls with most of these frameworks having the life span of a fruit fly. Think Angular, React, Ember, Meteor, Backbone, Knockout, Express, Mithril, Aurelia, etc., etc., etc.

Ember is nearly 5 years old. I don't use it, but it's very much a mature project.

It was hyperbole. Of course, most of these frameworks are still around, but their popularity waxes and wanes with each new kid on the block (React is the latest).
As is Backbone (5 years+), as is Angular (6 years), as is Meteor (4 years+), as is Express (6 years+), see a pattern?
As I am reading this, my reaction is "Don't let perfect be the enemy of good"
Which would be fine if you consider JavaScript good, I don't, it's at best passable if you avoid most of the land mines which is an art in and of itself and that's just the language, if you include the ecosystem it's pretty much all landmines.
So, if I take your favorite language and somehow manage to cause its ecosystem to get as bad as you claim Javascript's is, does that mean your favorite language is now bad?
But why did the ecosystem get out of hand so easily? Because the sloppiness of the language encouraged it or made it easy to abuse it. JavaScript's ecosystem is notoriously bad in this respect (cf. with Java or Python or Ruby).
I totally disagree with that, but that's just my opinion.
I think it would, yes.
That's really sad.
Why? No matter how great the language itself is it's a small part of what you actually end up needing to spend your time working with.
Check out his facebook feed... a theme definitely emerges. https://www.facebook.com/richard.eng1
Well, the previous generation of developers (or maybe that's more than one ago) came here via BASIC. As it turns out, availability trumps theoretical beauty when it comes to learning.
This article is over five years late. Get over it: JavaScript is a usable language.
I love javascript, and if love is wrong I don't want to be right!
Une debliteration de conneries non fondées, comme d'habitude.

Stupid article.

it works
Maybe developers value it's simplicity over it's ability to tick functionality boxes? I know I do.

Same with PHP and JAVA. Dysfunctional languages, yes. But fun and easy to use.

I'm not sure I'd call it "simple." There are a lot of complexities created by the desire to make it easy to implement one- or two-liners.
Sorry, I meant it's simplicity in it's pick up and play-ability. It's very easy for beginners to learn Jquery and JS because it doesn't come with the arcane syntax bloat that OO Languages have (void function etc. etc. ).

In terms of (Power)/(Time to Learn) Javascript comes very high, if not top.

Well sure, but when you want to develop larger applications you end up learning to need a lot of stuff that is harder to understand (like I don't think there is anything intuitive about IIFEs or that sort of thing)