News for hackers. Stuff that matters.
Re:Node_modules: One character saved 50 GB of disk space by jeroenhd on Friday September 30, 2022 @07:15PM (#33041922)
> Like, let's introduce a dependency for decrement lol

Here's a package that basically does that: https://www.npmjs.com/package/number-precision

Not entirely unreasonable as all `number`s are floats by default in JS, but the implementation of the entire package (https://github.com/nefe/number-precision/blob/master/src/ind...) is less than 100 lines of code and actually contains a method called "minus".

The very worst JS packages I've seen have got to be is-odd and is-even. 430,796 and 202,268 downloads every week, I kid you not!

Re:Node_modules: One character saved 50 GB of disk space by viraptor on Friday September 30, 2022 @07:35PM (#33042091)
Seems like a perfect candidate for a drive by fix. If you see it in your dependency tree, fix it in the project that uses it.