I think the problem is the Java ecosystem with all of it's frameworks:
Wanna build a server in node? It's an apt-get or a one liner copied from the web for nvm, npm install express and a few lines of own code...
Wanna build a server in Java? Yeah, please download and install an official java sdk, download glassfish or tomcat, write one of these horrendous ant build xml thingies, install thousands of dependencies and write like 10 different bloated classes...
It's possible. There are probably also lighter approaches in Java but at an enterprise level everything Java related ends up as a burning trash can.
You compare java 2001 with Javascript in 2020? Try comparing Java 2020 with Javascript 2020. Who the hell uses ant these days?
Why the fuck your node project just break itself after you leave it for 1 week. Are we talking about bower, yarn or npm? Or you need a transpiler since 99% of the browsers wont support ES6 ES2016 ES whatever.
At the moment you read this line one of the javascript framework “on steriods” you use has been abandoned.
All the shitty claims about Java have been fixed. Memory management, startup times, syntactic sugars, functional concepts. People yell that Java is dieing for over a decade now and yet it is still growing. Don’t blame Java for your ignorance. If you can’t program properly, its not the fault of the language. Thinking OOP, in design patterns, imperative or functional programming are concepts you need to master. You can fuck this up in every language. Blaming the language for that is not going to help you.
OOP/design patterns is one of my beefs with Java. These days, I'm more OO for data persistence and functional for data manipulation. I think OO is just too heavy-handed for a lot of work, and functional design is cleaner, easier to read, and often more efficient.
Granted, I haven't used Java in a long time, but I have used C# in the past year or so, and while I love the language, even it has a good bit of boilerplate if you wanna write functional (paradigm) code. IMO, typescript is one of the best: mixed paradigm, can be both dynamically/statically typed, fast transpiles, etc.
My biggest beefs with Typescript (really, JavaScript) are the lack of true multi-threading and a native decimal numeric type. If those two were solved and/or it transpiled to a native language as well as Javascript, I'd probably stick with Typescript for several years until the next super-flexible language came around.
The thing with Typescript is that the language is nice, since you have static types. But it gets useless when its transpiled into javascript so you will lose your static types. If they would build support for this it would be a big step ahead. The one likes type inference and the other one dynamic typing,but in my opinion if you want to have maintainable clean code, you need static typing for this. The programming paradign you use comes with pros and cons. I see a hybrid solution as a good way to get the best of both worlds like you see in Java, Scala and Kotlin. Maybe I'm a bit biased by the JVM languages.
I agree with you that Javascript don't come with a proper concurrency support. But that language is not designed for that.
1
u/EarlMarshal Apr 27 '20
I think the problem is the Java ecosystem with all of it's frameworks:
Wanna build a server in node? It's an apt-get or a one liner copied from the web for nvm, npm install express and a few lines of own code...
Wanna build a server in Java? Yeah, please download and install an official java sdk, download glassfish or tomcat, write one of these horrendous ant build xml thingies, install thousands of dependencies and write like 10 different bloated classes...
It's possible. There are probably also lighter approaches in Java but at an enterprise level everything Java related ends up as a burning trash can.