DEV Community

Discussion on: Do you think writing clean code is a bit difficult in javascript compared to other languages ?

Collapse
 
aminnairi profile image
Amin

I agree with all of your points.

JavaScript prototype-based was one of the hardest points and I spent a long time understanding it coming from C & C++.

Recently, with the ECMAScript standard, they tried to make it look like a real OO language by adding some keywords like class or static but it is just syntactic sugar over this prototype-based programming paradigm. And since they are two different concepts, this OO emulation in JavaScript is nowhere near complete compared to PHP or C++.

In my opinion, it was a huge mistake. They should have gone to a more procedural path, or even functional, it would have been far easier to take, again still in my opinion.

It's funny how I can relate to your comment. I feel less lonely now. Haha!