In this tutorial you will learn about the How to fix “module was compiled against different Node.js version” error and its application with practical example.
How to fix “module was compiled against different Node.js version” error
You need to remove the respective module folder (bcrypt) from the node_modules folder and install it again, using following commands –
1 2 |
rm -rf node_modules/bcrypt npm install |
Or you can simply rebuild the package and tell npm to update it’s binary too, use following single command to get it fixed –
1 |
npm rebuild bcrypt --update-binary |