LoginSignup
Ago02
@Ago02

Are you sure you want to delete the question?

If your question is resolved, you may close it.

Leaving a resolved question undeleted may help others!

We hope you find it useful!

npm startをした際に内部コマンドまたは外部コマンド、 操作可能なプログラムまたはバッチ ファイルとして認識されていません。と表示される

解決したいこと

npm start をターミナルで実行したい

例)
npm start を実行したいのですが以下のようなエラーが発生しました。
解決方法を教えて下さい。

発生している問題・エラー

> trank@0.1.0 start
> react-scripts start

'react-scripts' は、内部コマンドまたは外部コマンド、
操作可能なプログラムまたはバッチ ファイルとして認識されていません。

自分で試したこと

npm install を実行すると以下のようになってしまいます、、、

npm WARN ERESOLVE overriding peer dependency
npm WARN While resolving: react-side-effect@1.2.0
npm WARN Found: react@18.2.0
npm WARN node_modules/react
npm WARN   react@"^18.2.0" from the root project
npm WARN   16 more (@testing-library/react, react-beautiful-dnd, ...)
npm WARN
npm WARN Could not resolve dependency:
npm WARN peer react@"^0.13.0 || ^0.14.0 || ^15.0.0 || ^16.0.0" from react-side-effect@1.2.0
npm WARN node_modules/react-side-effect
npm WARN   react-side-effect@"^1.1.0" from react-document-meta@3.0.0-beta.2
npm WARN   node_modules/react-document-meta
npm WARN
npm WARN Conflicting peer dependency: react@16.14.0
npm WARN node_modules/react
npm WARN   peer react@"^0.13.0 || ^0.14.0 || ^15.0.0 || ^16.0.0" from react-side-effect@1.2.0
npm WARN   node_modules/react-side-effect
npm WARN     react-side-effect@"^1.1.0" from react-document-meta@3.0.0-beta.2
npm WARN     node_modules/react-document-meta
npm ERR! code ERESOLVE
npm ERR! ERESOLVE could not resolve
npm ERR!
npm ERR! While resolving: react-smooth-dnd@0.11.1
npm ERR! Found: react@18.2.0
npm ERR! node_modules/react
npm ERR!   react@"^18.2.0" from the root project
npm ERR!   peer react@"^18.0.0" from @testing-library/react@13.4.0
npm ERR!   node_modules/@testing-library/react
npm ERR!     @testing-library/react@"^13.4.0" from the root project
npm ERR!   15 more (react-beautiful-dnd, react-calendar, ...)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"^16.3.0" from react-smooth-dnd@0.11.1
npm ERR! node_modules/react-smooth-dnd
npm ERR!   react-smooth-dnd@"^0.11.1" from the root project
npm ERR!
npm ERR! Conflicting peer dependency: react@16.14.0
npm ERR! node_modules/react
npm ERR!   peer react@"^16.3.0" from react-smooth-dnd@0.11.1
npm ERR!   node_modules/react-smooth-dnd
npm ERR!     react-smooth-dnd@"^0.11.1" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR!
npm ERR! For a full report see:
npm ERR! C:\Users\ひるま\AppData\Local\npm-cache\_logs\2024-03-08T04_26_44_529Z-eresolve-report.txt

npm ERR! A complete log of this run can be found in: C:\Users\ひるま\AppData\Local\npm-cache\_logs\2024-03-08T04_26_44_529Z-debug-0.log
0

1Answer

認識してないなら install すればよいのでは?と。

npm install react-scripts

とか?

0

Your answer might help someone💌