Help request to compute the amount of disk space and bandwidth wasted by useless published items? #178676
Unanswered
ericmorand asked this question in npm
Replies: 2 comments 8 replies
This comment was marked as off-topic.
This comment was marked as off-topic.
Uh oh!
There was an error while loading. Please reload this page.
-
BetaWas this translation helpful?Give feedback.
2 replies
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Select Topic Area
Question
Body
Dear maintainers,
I'd like to conduct a survey about the amount of disk space and bandwidth wasted on the npm registry by items that are never used by package consumers - i.e. items that are published in the registry and are never imported by projects and / or products, because they technically can't be imported or because they are not supposed to be.
Typically, the following items are a waste of resources, hanging around, only taking space in the registry and in the client systems:
If you need an example of what I mean,
svgicons2svgfontis a good one:https://www.npmjs.com/package/svgicons2svgfont?activeTab=code
The package comes with sources, source maps, tests, and a package.json that holds 190 line when only around 80-90 are actually needed to consume the package. It consumes 425KB on my computer, when only 280KB are reachable and required to make it work. Around 30% of its size is just wasted.
My objective is to compute the total amount of space occupied by this uneeded published information, accross all packages (public and, ideally, private) in order to write a paper about it and, hopefully, raise awareness and initiate a change in both npm and client sides.
Is there a way to achieve such a thing, using a public API, or maybe by having access to some data that npm's maintainer are likely to possess? I don't care about the content - except for package.json files. I'm only interested in file types (path and extension) and their size.
Thanks in advance,
Eric.
BetaWas this translation helpful?Give feedback.
All reactions