I think I might have ran into a glitch. Last night I ran into an error that said "Could not find plugin "proposal-class-static-block". Ensure there is an entry in ./available-plugins.js for it." Everytime I add or delete code in my react website it will run this error, what do i do??? I tried npm install --save-dev @babel/plugin-proposal-class-static-block but that didnt do anything at all. Anyone have a solution?
Adding my fix in the event someone experiences this error.
Other people have fixed it by running an npm install and/or deleting the package-lock.json lock file and then running npm install.
Those didn't work for me so I figured out the module files causing this error are related to a conflict with older versions of babel/core and babel/preset-env. The versions that fixed my issue were:
"@babel/core": "^7.14.6", "@babel/preset-env": "^7.14.7",
I added the updated versions to my package.json and running npm install. I'm assuming this fix will work with Yarn also. If you keep getting errors when updating your modules, try running npm install --force. However, please readup on what this does if you are unfamiliar.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With