bezumkin / orbita

Self-hosted blog with subscriptions
https://orbitacms.ru
MIT License
69 stars 13 forks source link

Change package manager on pnpm #8

Open Alex-Andr-19 opened 3 days ago

Alex-Andr-19 commented 3 days ago

Project's package manager is npm, but this technology is so old and has many misstakes on optimisation case. It creates many duplicates of the same packages in node_modules and another reason for change npm is install dependencing packages with missmatching of versions. Example, project has package A with dependency of C with version 1.1.5 and package B with dependency of C with version 1.0.5. Last versioin of C that would be loaded is 1.0.5. npm can create incidence that would be import in package A package C with version 1.0.5, but package A should use newer API of C.

I prefer use package-manager pnpm.

bezumkin commented 2 days ago

Sorry, but pnpm is not included in the official Node Docker image we are using. I don't want to create a custom image until I'm forced to do so.

I believe npm is "old, but not obsolete"(c).

Alex-Andr-19 commented 9 hours ago

You can just install pnpm in your image and docker will just cache it. You can do it on step after clone node image and cache the installation of pnpm would be saved by long time.