If you are using parcel then try to delete ".parcel-cache"
folder. And then Rerun the build.
Deleting .parcel-cache
folder works fine.
Instead of every time deleting it manually, you can simply add rm -rf .parcel-cache &&
before your start
, dev
or build
command in package.json
.
package.json
{ ... "scripts": { "start": "rm -rf .parcel-cache && parcel", "build": "rm -rf .parcel-cache && parcel build" } ... }
Remove-Item -Recurse -Force .parcel-cache
when you run Remove-Item -Recurse -Force .parcel-cache, it will forcefully and recursively delete the .parcel-cache directory and all its contents. Use this command carefully, as it permanently removes the specified directory and its content.
then run npx parcel <entry point(like index.html)>
You can also use npm cache clean &&
before npm Start
and npm run build
, this command is used to clear the Parcel cache.