open-services / open-registry

Community Owned JavaScript Registry
https://open-registry.dev
MIT License
266 stars 8 forks source link

Cache original metadata response without rewriting #24

Open victorb opened 5 years ago

victorb commented 5 years ago

Currently, when retrieving a new package from npm registry, Open-Registry rewrites the URL of the tarball to point to Open-Registry and then saves the package to cache.

Instead, we should allow more flexibility, and write both the changes metadata + the original, so if in the future we decide to point the tarball somewhere else, we can change it on runtime.