News for hackers. Stuff that matters.
Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by kcb on Sunday January 09, 2022 @09:15PM (#29869802)
Use a language where you don't need to pull in 100 dependencies to create a useful application/service.
Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by LAC-Tech on Sunday January 09, 2022 @09:51PM (#29870024)
It's not a language problem. It's a cultural problem.

Last I checked create-react-app pulls around 1k transitive dependencies. Can't really blame JS for that, can we?

Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by ajdude on Sunday January 09, 2022 @11:48PM (#29870790)
This whole situation reminds me of that post a little while ago

> I will pay you cash to delete your npm module

https://news.ycombinator.com/item?id=29240952

Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by a3w on Monday January 10, 2022 @12:36PM (#29878374)
So finally F.L.O.S. Software pays out. Shame that the dev did not apply for some compensation. All in all, not very rational of him.
Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by tomjen3 on Monday January 10, 2022 @01:06AM (#29871220)
Keeping dependencies loosely coupled and reusable has been best practice since forever, but it is only really with NPM that it has become the default.
Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by chrisandchris on Monday January 10, 2022 @06:47AM (#29873343)
But actually it's more like dependency hell because you pull in the same dependency in N versions and you can't update transitive dependencies in a senseful matter? And you get a lot of libraries that are like 4 lines and computing basic operations (like there was a lib "isOdd"... i mean x% 2 === 0?).

So you won't gain anything from this type of dependency management, because it is way to complicate to understand and to manage for a developer.

Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by rtpg on Sunday January 09, 2022 @10:04PM (#29870109)
unfortunately almost all languages are moving towards smaller, not bigger, standard libraries.

I do think there is space for someone to ship an "unofficial meta-package" for languages like JS to wrap all this stuff (I tried to do an analysis of npm once to figure out what would make sense but got lost in the weeds....)

Python (for me one of the gold standards on this front) has been hyping for a future with a much smaller standard lib and it makes me sad.

Re:Dev corrupts NPM libs 'colors' and 'faker', breaking thou... by nailer on Monday January 10, 2022 @12:28AM (#29870985)
Cool use a lang without a developer ecosystem got it.