Node isn't a good language, it isn't even a mediocre one
I was reading this article on Medium.com "What Will Be the Best Back-End Framework for 2021? Node.js/Express vs. Django vs. Spring Boot" https://medium.com/better-programming/what-will-be-the-best-back-end-framework-for-2021-c3ad1beb0f44 do please give it a read.
Unlike the author this year has been very busy for me in all areas. From Microservices, Kubernetes, Netlify, Docker, to the new release of Sitecore 10 and tons of other stuff. The COVID world has changed the way a lot of clients do business and people in technology are going to be at the front of that change. The introduction of the article I agree with very much.
Some people don’t like change, but you need to embrace change if the alternative is a disaster.
- Elon Musk
But so much about this article annoys me I couldn't help but blog about it.
"As we can see, JavaScript is at the top, as always."
Given that JavaScript underpins every modern browser and those browsers offer literally nothing else that isn't exactly surprising. It's like taking the Queen hostage and saying "As we can see, the Queen is enjoying her holiday with us...".
Oh yeah, we could always use Flash I guess?
78.9% of the internet is PHP which the article totally ignores, guess what? Next year 78.9% of the internet will be running PHP. I hate PHP for numerous reasons but its usage really isn't going to change in a year. The language you are talking about is 8th in the rankings for most used. Ruby has four times more of a chance of replacing PHP than Node does.
I highly recommend giving The JavsScript phenomenon is a mass psychosis a read.
At my new company, everyone was pretending that JS was alright. I got tired and spoke up. Turns out, deep down they all hated JS, it was just crowd thinking. Now they all hate JS. And we’re waiting impatiently for Web Assembly.
Another post puts it equally well
Node.js is one of the worst things to happen to the software industry in recent times, a whole generation of programmers are being taught the worst of all ways of doing concurrency, in a system that doesn't scale either in performance or project size and with one of the languages most plagued by pitfalls ever created.
JavaScript was already painful enough in the browser, why on earth anyone ever thought it was a good idea to use it on the server boggles the mind.
We will be paying the price of this misguided hyped fad for decades to come.
Of all the ways of doing concurrency, callbacks are by far the worst, Twisted was plagued by them and is the main reason why it failed, and that was with a much more sane and reasonable language like Python (stackless Python was a much better alternative and used a model similar to Go's CSP).
And the sad thing is that there are much better alternatives around with much more sound models and environments, Erlang and Go are the two obvious examples, and that is for the highly specialized situations where you have great concurrency needs, for any other problem anything else will be much better than Node.js, even PHP.
It's hard to explain why Node is an awful language, it's like asking why is C++ better than C. Or why don't we just build everything in assembly, just because you can, doesn't mean you should.
I've developed a lot in VB6, in terms of functionality the same as JavaScript. By upgrading JavaScript you made it equivalent to a 22-year-old language, congratulations well done. Guess what we are all years down the road from where you are now as a language.
Everyone harps on about Nodes amazing features, the features that have been in most modern languages the last 20 years. An incredible package manager full of code. As if large amounts of code shows quality, also how else are you going to fill the gap between JavaScript and anything modern.
They also talk about the amazing concurrency it provides. Anyone who knows the slightest thing about concurrency will want to cry. Even more so when they discuss its incredible performance. A system that has worse performance than Haskell a 31-year-old language. Or .NET Core Microsoft new kid on the block.
The point I'm trying to make is any decent modern language the above 'benefits' are expected. The language you use should improve upon its origins, C# took all the good stuff from C++, Java, Delphi, and Smalltalk and tried to obliterate the problems. All these years down the road it has massive improvements in all areas even from its beginnings.
There are seven languages I can think of off my head all of which are better than JavaScript. Seriously if you think Node appears to be the better option than what you are currently working on, use anything that isn't Node or your current language.
Node is stuck ~20 years in the past, wondering if it's going to get its day in the sun. If this is the best we can do on the shoulders of the incredible devs that came before us then quite frankly we should all quit and do the world a favour.
About Me
As a Tech Lead for Sagittarius marketing who I have been with for the last twelve years. I oversee a team of seven working pods, including numerous developers and contractors in multiple global locations. This involves supporting the developers with coding issues, meetings and phone calls with their clients and going out of pitches with potential new clients.
I have extensive experience building and supporting Sitecore websites from Sitecore 6+ including Helix pattern, I scored 100% in the Sitecore 7 certification exam. Experience managing and maintaining SQL Server, integration with numerous third parties such as Salesforce, AppDynamics, New Relic, Dynamics CRM and many payment gateways.
The first Sitecore website I developed was Skiweekends which was architected and developed by me. It won the Sitecore Experience Award the main award during the Sitecore Experience awards ceremony and the Sitecore Best Travel & Tourism award. I also was lucky enough to perform the first Sitecore 8 upgrade within the United Kingdom for Liberon.
Personally I have had the honour of being recognised in several award ceremonies. Including the BIMA 100 awards in 2019 in the Tech Trailblazers category and previously in the Dev's and Makers category. I’ve been highly commended twice in the Wirehive 100 Techie of the Year awards. Due to my involvement in many aspects of Sagittarius work, many of the awards for their clients I've also been involved in.
About the author
Richard Brisley
I'm a multi-award winning Sitecore developer. Currently working for Sagittarius Marketing as a solutions architect to understand customer needs and produce multi-national high-performance websites.