Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
383 views
in Technique[技术] by (71.8m points)

reactjs - npm create-react-app myapp gives error Command failed: create-react-app spawn EPERM

Months ago, on my home PC I installed nodejs, react, etc., and got various tutorial sample projects working. Now I’m remoting to my up-to-date Windows 10 work PC to install everything.

I’ve done the setup steps from the Traversy Media React Crash Course tutorial (5 stars), also just now, to double-check, watched the 1-minute video and reviewed the simple instructions at https://www.techomoro.com/how-to-install-and-setup-a-react-app-on-windows-10/ .

So I’ve installed nodejs from https://nodejs.org/en and downloaded react-0.14.3.zip (but there’s not an .msi installer, just a build folder and an examples folder… am I forgetting or missing something?)

Installed create-react-app globally: PS C:usersmolindevmyapp> npm install -g create-react-app …which spewed out… C:UsersmolinAppDataRoaming pmcreate-react-app -> C:UsersmolinAppDataRoaming pm ode_modulescreate-react-appindex.js [+ sign] [email protected] updated 1 package in 7.639s

When I’m a level above the myapp folder and do either of these: npx create-react-app . npx create-react-app myapp …or if I’m in the myapp folder and do either of these: npx create-react-app myapp npx create-react-app .

… I get the error: Command failed: create-react-app spawn EPERM

Per a suggestion on a board, I ran this and retried, but no joy. npm cache clean --force I even rebooted and tried again.

No events show on the Window Event viewer. Is this a permissions error on my work PC?

Thank you for any advice!

question from:https://stackoverflow.com/questions/65874541/npm-create-react-app-myapp-gives-error-command-failed-create-react-app-spawn-ep

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Reinstall react app globally
npm i -g create-react-app

Recreate your app - create-react-app
(maybe this will help)


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...