0

I want to create a build file for node and run it but I am facing errors on my local machine.

I've produced a build file using npm run build. Copied it to another directory with package-lock.json and installed them, and ran npm run preview to preview it but it is giving me this error:

enter image description here

However, when I run the same build inside my project directory, it works, but when I copy it out and paste the build folder in another directory then it gives me this error.

What is happening?

Abhay Salvi
  • 890
  • 3
  • 15
  • 39

0 Answers0