nxhack / openwrt-node-packages

OpenWrt Project Node.js packages. v18.x TLS and v20.x LTS

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add option to keep npm cache

nxhack opened this issue · comments

To speed up build time, we have added an option to keep a cache of npm packages.
Enabling this option will reduce network traffic and parallel-build times.
The npm cache for all this repository will take up about 7.5 GB of storage.

This option is available in the configuration menu of "node" package.

Known Issues:
The following error occurs

npm ERR! notarget No matching version found for [NPM-MODULE].
npm ERR! ERESOLVE unable to resolve dependency tree

That is an issue with the stale cache. It does not update to newer npm packages.
The workaround is to remove the matching npm cache.

Example
If you have this issue with node-npm-check-updates, please remove the cache as follows.

cd [NODEJS_NPM_CACHE_DIR]
rm -rf npm-cache-npm-check-updates