1

I am getting error Cannot find module 'bcrypt' in nodejs application

I have tried to install it using npm install bcrypt but still getting the issue

npm i bcrypt

enter image description here

MEDZ
  • 2,227
  • 2
  • 14
  • 18
  • Did you install the Destkop development with C++ workloard as suggested following the link ? –  Jan 20 '20 at 15:36

1 Answers1

0

It is trying to build bcrypt from source, but you don't have the necessary tools installed for it to do so.

Try installing the Visual C++ Build Tools first, which can be done using the following convenience npm package:

npm install -g windows-build-tools

Once that is complete, run npm install bcrypt again.

More info here: https://www.npmjs.com/package/windows-build-tools

sdgluck
  • 24,894
  • 8
  • 75
  • 90