4 ms·
It’s slowly expanding, but JS has an anemic standard library. The node platform adds a little, but yo’re still miles away from a typical standard library like J
by jaredklewis 7y ago
It’s slowly expanding, but JS has an anemic standard library. The node platform adds a little, but yo’re still miles away from a typical standard library like Java or python.
If you want to have 0 dependencies, you will have to write a lot of code to do things that would just be a line or two in most other languages.
- ausjke 7y agoI have long hoped Nodejs has a "standard library" of its own
- vbezhenar 7y agoThe problem is not with anemic standard library. The problem is with lack of commonly accepted set of libraries. Java is not so good. You can't even copy one stream to another in Java 8. There's no built-in DI. There's no built-in ORM. Even built-in logging is so bad that everyone uses something different. Hell, no built-in JSON in 2019. But there's set of community-adopted libraries and everyone's using them. You need more utility methods? There's Guava (and, sometimes, apache commons). There's no left-pad library. You need DI? There's Spring. You need ORM? There's Hibernate. You need logging? Well, here's some competition between logback and log4j and that's about it. And even that competition has plenty of adapters which allows to write library code that works fine with both. So JS community should throw left-pad in the window and declare underscore.js as a library of choice, so every other library will depend on it and that's about it.