DEV Community

Sotiris Kourouklis
Sotiris Kourouklis

Posted on

Why JavaScript is a mess.

Nowadays, programming is a well established field in the market with more and more new technologies popping out of nowhere. I started programming almost 3 years ago, with a well know language called "JavaScript". So what are the problems and what my concerns about the JavaScript ecosystem.

The small problem.

JavaScript is the foundation of the the internet, most use JavaScript on the front-end part of their website. JQuery, Vuejs, Reactjs, Angularjs are some of the frameworks. But what is the problem with all of them? Well eslint is the problem, and no eslint is a great tool but the need to use eslint a the real problem. You learn to write React one way, then you go to a company and they write react another way. Then you edit some "legacy code"(just 2 years old) and they write React another way. Some use hooks, some don't, some use es5 some don't.

In conclusion, the result is always the same, the differences are minimal. Yet you are going to say, "but no, the bundle size changes, the performance change and the lines of code we write changes". Going from 6mb to 5mb is not going to change anything, going from 200ms to 170ms is not going to change anything, the only thing that I agree is the simpler code. But simple is not re-learning the same technology every 2 months.

The big(huge) problem.

Let's talk about the back-end. 7000 frameworks there are. All producing the same result with a different way. There is not a single folder structure to follow, everyone use's their own folder structure, there is not a single coding style, everyone is writing with there own style, even when using the same framework.

I am using express to write code, every-time I start a new project I need to spent 8 hour just to configure eslint, prettier and typescript to the needs of the project, and when a new developer jumps in, he needs to spent another 8 hour to figure out the coding style of the project. Also thanks god I learned Typescript because with JavaScript things where even worse.

What is my suggestion.
In a nutshell, I love JavaScript and I use it everyday, yet above I mentioned some of my concerns. Large corporation can handle this type of issues, but when it comes to the individuals it is harder that it seems. Learning is something developers need to master, however when it comes to learning the same thing again and again, sometimes it is a little nerve racking. What I suggest to the community is to find a single framework to work. Next.js is now the most popular on the front-end. On the other hand on the back-end language like Golang, Python or even Ruby are more stable than Nodejs and from company to company coding style doesn't change much so stick with those.

Thanks for reading,

Sotiris

Discussion (3)

Collapse
starptech profile image
Dustin Deus

The only reason to do full-stack Javascript is to simplify hiring and reducing the cost of technology diversity. If it enforce you to use the wrong tool for the job it will cost you a lot more. I enjoy Node.js for a small number of areas. It's easy to learn and the community is amazing but there are much better ways to build complex business applications these days!

Collapse
sotiriskourouklis profile image
Sotiris Kourouklis Author

I totally agree Dustin , great point .

Collapse
pedrodlafaria profile image
Pedro Faria

Hi Dustin, I'm currently learning Node and I'm interested in your opinion. Can you expand on your statement? What is your preferred way to build complex business applications nowadays? Thanks!