Hacker News new | ask | show | jobs
by gasping 4178 days ago
This is why Node.js is receiving an enormous backlash from the programming community. People keep peddling it as a solution to all problems when in reality it has very limited utility in all but a few use cases. Pushing this thing over old CGI technology and adding a hideous spaghetti-code HTML interleaving syntax is akin to shoving it further down the throats of the masses who don't want or need Node.js. The best thing to do is leave Node.js in its corner of the ecosystem and let people find it if they need it. Why are we even talking about CGI? It's 2015. This does nothing good for the developer ecosystem.

I've got a running theory for the next 10 or so years of development. Node.js's sole purpose was to lower the barrier to entry of server-side development. With the barrier to entry lowered, inexperienced developers with no knowledge of proper tooling are beginning to reinvent the wheel and make the same mistakes we did 10 or fifteen years ago. We're going to see a tragic repeat of the worst decisions made over the past few decades only this time they'll be running on what is arguably one of the most poorly designed programming languages, Javascript. Those who are too inexperienced to understand history are doomed to repeat it.

5 comments

Node.js's sole purpose was to lower the barrier to entry of server-side development.

async nature of nodejs, prototype based OO, callback hells and scope chain make JS harder than Ruby and Python, IMHO.

I dont think nodejs lowers the barrier. Or am I mistaken?

You're quite right. Node.js is more like a trap for inexperienced developers who probably won't even understand why Node.js is an awful tool when used to solve the wrong problem because they have no real experience (I believe Node.js is the wrong answer to the wrong problem in all but a very few exceptional circumstances).
While I am on your side of the fence, there are a lot of those whose sole language is Javascript (learned from client-side) and have no time/motivation/ability to learn a new language. For them, wouldn't it be cool if they could use their existing knowledge and develop on the server?

I'm not saying it's a good or bad thing, I'm just saying that's how it is.

I don't think so. I'm all for lowering barriers to entry but there is a point where it becomes harmful to the ecosystem and to the developers themselves. Software development is, in my opinion, an engineering discipline, and so it's hugely important to use the right equipment for a specific task. If somebody truly can't learn how to do server-side development properly then they need to pass the job onto someone who can. Software development is hard. Not everyone can do it. This isn't a bad thing. Understanding that software development is hard allows us to move forward and gain a more broad knowledge of our field. Ignore that, and we end up repeating history. See: the templating syntax in node-cgi. There is no reason for that to exist in 2015. This is not how we advance a STEM field.

    > it's hugely important to use the right equipment for a specific task
Yet almost everything is built with a tool that's merely good enough for the task. Which usually makes it one of the right tools.

You mention that "software development is hard" and even manage to talk about advancing the STEM field, but we're talking about handling some http requests and someone's weekend project that managed to register a domain name.

What is the right tool anyways? PHP as a CGI? Haskell? Does it matter?

Bottom line is that you're getting wound up by a project that has 9 commits. The last one was 2 months ago. I think your PHP job security is safe for now, my friend. https://github.com/UeiRicho/cgi-node

> Yet almost everything is built with a tool that's merely good enough for the task. Which usually makes it one of the right tools.

I agree with you there so long as you understand which tools are good for which tasks.

> we're talking about handling some http requests and someone's weekend project that managed to register a domain name.

Node.js and cgi-node are not marketed as being strictly for weekend or toy projects. In fact, cgi-node is marketed as a tool that can do everything except cook your breakfast (see the last sentence of the cgi-node homepage). This just shows how badly over-marketed these products are.

> What is the right tool anyways

It's going to depend on the problem. Node.js's major failings are in the (arguably) poorly designed programming language and the continuous passing of callbacks. If your product can work within those constraints then Node.js might be the right choice. For most people Node.js will not be the right choice.

> Bottom line is that you're getting wound up by a project that has 9 commits

I don't care about how big or small the codebase is. I just care about it being marketed as a valid solution to most problems when it's really just a trap in most cases.

> I think your PHP job security is safe for now, my friend.

Pointless personal jab based on an incorrect assumption. I do not work in PHP and I don't see Node.js as a threat to the job security of any competent developer.

But there is a big difference between "professional" (their work affects others) and "hobbyist" (simple tasks nobody uses).

Think about the hobbyist... The PHP/Razor like templating, since you mentioned it, gently mixes known (html document that they can see) with the unknown (magic code). Do they really need anything more advanced for the type of things they're trying to produce?

Node.js is great for REST API development but hey who's using those these days right ?

But I agree that this project fixes a non-existing problem.

I agree that Node.js is pretty good for thin REST APIs, it's one of the few scenarios that Node.js actually works quite well. It's the other 99% of use cases that I take issue with.
Use cases like Walmart, LinkedIn, Paypal, Ebay, the New York Times, Uber, Voxer, Microsoft and Yahoo?
They aren't use cases. They are company names. Which parts of their product runs on Node.js? And have you spoken to their developers about their projects? Just because a big company deployed something doesn't make it viable.
I don't understand what you mean by "shoving it further down the throats of the masses". Are people being ordered to use Node.JS against their will somewhere?
Yes, usually by their manager. Things like Node.js get over-marketed to the public, managers are fooled into thinking it's a valid solution to their problem, then they force developers to use it against their will. node-cgi increases the number of scenarios where Node.js can be inappropriately forced down the throats of otherwise competent developers.

And there's also the long tail of inexperienced developers who made their own decision to use it and left a broken application that an experienced developer is called in to fix.

I also prefixed my statement with "akin to", which is to say it's not literally being shoved down the throats of developers but the effect is similar.

Well, if that is the case, maybe the issue is that such a person works in a bad environment? If you have a boss foisting technical decisions on you that are not suitable for the project, I'd expect that is a messed up environment in a lot of other ways. Is that Node's--or it's practitioners'--fault?
I think we have a nomination for the best troll of the year already. :-)