I have a node module rimraf. It definitely exists based on being able to click on it
and land on its folder under the node_modules. But I get errors saying command not found
for rimraf.
Tried to delete the entire node_module.
Also tried following commands.
npm ci
and
npm cache clear --force
npm i
No errors, some warning messages about licensing and
No repository field found to a module drive-module.
Now when I run following command, I end up with error.
npm run build
Error
sh: rimraf: command not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! dyna-modules@0.2.0 build: `rimraf build && bundle-trace-app --clientConfig webpack/client.config.js --serverConfig webpack/server.config.js`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the dyna-module@0.2.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
What would be the issue? Considering that rimraf exists?