Hey developers 👋
I had to quit the conversation as it was a birthday ceremony and I didn't want any fight. :)
this properly and if I'm not paying attention, I can do something wrong with it even nowadays.
People who tell that JS doesn't scale probably forgot to tell that to Paypal, Netflix and many other big companies out there. Here ns Brazil there is big bank whose API layer is (or was about 3 years ago) entirely written in Node.js. Even Microsoft has embraced it.
In the end, it all comes around to that old saying:
There are only 2 types of programming languages: the ones people complain about and the ones nobody uses.
Thank you for inviting me. Imho, it does not matter if the person is a 90's dev. They clearly missed the past few years of development in the JS ecosystem. It is true that many years ago JS was ugly and not scalable, however it grew. A lot. We have so many new ways to scale JS, so many ideas to workaround JS weaknesses and so many strong new features. It is best to tell people who probably don't know better to first go and research the topic. If they don't, try to keep away, because such people tend to be toxic.
JS has a stigma, and especially the devs who don't work a lot with JS might have missed all the cool new stuff.
I would take that "advice" with a grain of salt. Think about this for a second:
You met a stranger and told him you use JS, and he told you to use Python instead.
Did he know the nature of the app? No.
Did he know the reasons you guys chose JS? No.
Did he know the platforms the app needed to run on? No.
Did he have specific, concrete examples of why Python is more scalable than JS? Doesn't sound like it.
Did he provide examples of a time when he tried to use JS for a specific app and then had to switch to Python due to problems with JS? Doesn't sound like it.
Yet he told you to change technologies... Do you see how silly this looks? Whether or not I'm pro or against JS, just based off of this alone, I wouldn't listen to this person unless they were able to articulate all of those things. These types of people exist in every environment. I don't think "JS has a bad reputation" as much as there are just people out there who find it fun to try and convince others of why they are right and the other person should be doing what they are.
I can think of 10,000 reasons to yell at him about why he should be writing his code in Rust instead of Python... But would I do that without understanding the problem domain, reasonings, history, culture, requirements, and provide specific examples? Absolutely not.
JS has long been a target of tech contempt culture. In the early days it was considered a bit of a toy, beneath the dignity of mighty gods of computer science (you know, people who learned Java at university ;))... and it never really recovered from that stigma, regardless of its evolution. Plus it was popularised during the early days of the web when things were relatively "wild west" - if it worked it shipped, and automated testing wasn't a thing yet - so JS was a bit of a shorthand for traditional programmers wanting to have a bit of a swipe at the web.
JS had two big things in its favour though - 1) it was the only scripting language supported natively in the browser; so people working on the web didn't spend a ton of time hand-wringing about whether their literal only choice was the right one. 2) it has an incredibly low barrier to entry. Much like PHP - you renamed .html to .php and just like that you had a new language to use! So heaps of people get into it because it's so damn easy to start. The quality of the language is only one aspect of its success. A low barrier to entry will make even quirky options like JS and PHP popular!
Some criticisms have evolved a bit eg. dynamic vs static types is a reasonable talking point; even if it's easily solved by using Typescript. But other people still act like we're talking about ES3, rather than ES6. Still others would say "X is terrible, use (my pet language)" no matter what X was.
But there's really no excuse for anyone acting like shipping JS prevents you from following good engineering practices. Also there is a mind-bendingly large list of languages that compile to JS as well, so absolutely nobody is "forced" to use it any more. So a lot of arguments just aren't relevant any more.
Is JS perfect? Oh hell no. Have heaps of businesses done really well with it? Yes. Is JS right for every app? Definitely not. Is Python right for every app? Definitely not. Is JS right for your app? I don't know and neither did the guy at the birthday party. I'm going to assume your team knows what it's doing better than anyone else!
What he said is generally true. But the same goes for most, if not all, languages.
If it werenʼt for all the quirks that must be in the language for backwards compatibility (which doesnʼt always work, actually), it could be great. On top of this, all engines are hastily written and are awful resource hogs. Most developers argue that itʼs reasonable to have a developer machine with 8+ CPU cores and 16+GB of memory, but while i can write the same desktop application in C on a much weaker machine, I disagree. It will even be more portable than Electron apps.
I can probably go on for hours, let this be enough. JS was not written for what it is (ab)used for today. Reimplement it from scratch, and you have a powerful tool. Until then, itʼs just an extension to Netscape Navigator.
I thought it is popular already!
Then Node came along. Personally, it took me a while to come around to Node for backend. Until that point, I was using Node mostly for server side rendering of react. I wrote my first node backend over the past 14 months on Google Cloud and it was generally a great experience. Admittedly, spending years in PHP, Python and Java, the biggest learning curve was to properly account for Promises and not doing non-performant things like array.forEach (vs. traditional for loops) with big datasets. I was skeptical at first of Node's single threaded nature, but I believe most concerns around that are simply misunderstandings of how it works.
I will say that part of my decision to adopt Node was ease of hiring circa Nov 2018. Initially, I planned the architecture to be a React front end supported by Python APIs. We were getting a lot more applicants for the React positions than the Python ones. Cross training was thus a lot easier and I think really helped the team as a whole on a variety of fronts.
I am exploring Full web dev and Data analyst. I love writing technical articles, contributing to open source projects and building community