We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I created a fresh create-react-app and added gh-pages to it. I go ahead and run
npm run deploy
and then I get this:
`npm run deploy
sorani.tech@0.1.0 predeploy npm run deploy
'npm' is not recognized as an internal or external command, operable program or batch file.`
I am not sure why this is happening...
The text was updated successfully, but these errors were encountered:
Does the your package.json have a predeploy that runs deploy?
package.json
predeploy
deploy
Sorry, something went wrong.
I had the same Issue please check your package.json and see if your scripts are in the right order
Here was what i had that caused the issue
"scripts": { "predeploy": "npm run deploy", <----------- "deploy": "gh-pages -d build", "start": "react-scripts start", "build": "react-scripts build", "test": "react-scripts test", "eject": "react-scripts eject"
Changing that word to the correct word "build" caused it to deploy correctly additionally I had issues when the scripts were not in the correct order
"scripts": { "start": "react-scripts start", "predeploy": "npm run build", <----------- "deploy": "gh-pages -d build", "build": "react-scripts build", "test": "react-scripts test", "eject": "react-scripts eject"
The code that fixed my issue was this
"scripts": { "predeploy": "npm run build", <----------- "deploy": "gh-pages -d build", "start": "react-scripts start", "build": "react-scripts build", "test": "react-scripts test", "eject": "react-scripts eject"
I hope that helps!
No branches or pull requests
I created a fresh create-react-app and added gh-pages to it. I go ahead and run
npm run deploy
and then I get this:
`npm run deploy
'npm' is not recognized as an internal or external command,
operable program or batch file.`
I am not sure why this is happening...
The text was updated successfully, but these errors were encountered: