Gatsby deployment to Netlify failing using bit.dev remote server
Original: on Stackoverflow
The culprit here is the use of a
bit.dev component registry server for one of your dependencies.
Here is the doc section to start following to setup on Netlify:
On Netlify, you cannot generate the file dynamically, and you should add .npmrc file in your project.
Add .npmrc to the project
You can add a
.npmrc in your project with the following:
Add the BIT_TOKEN as environment variable
DO NOT: replace the
BIT_TOKEN variable with the actual token in the
.npmrc file because it is public. Only put the token into the admin panel of Netlify explained in the linked docs.