You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './lib/tokenize' is not defined by "exports" in /Users/zzz/Develop/my-app/node_modules/postcss-safe-parser/node_modules/postcss/package.json
at new NodeError (node:internal/errors:371:5)
at throwExportsNotFound (node:internal/modules/esm/resolve:416:9)
at packageExportsResolve (node:internal/modules/esm/resolve:669:3)
at resolveExports (node:internal/modules/cjs/loader:482:36)
at Function.Module._findPath (node:internal/modules/cjs/loader:522:31)
at Function.Module._resolveFilename (node:internal/modules/cjs/loader:919:27)
at Function.Module._load (node:internal/modules/cjs/loader:778:27)
at Module.require (node:internal/modules/cjs/loader:999:19)
at require (node:internal/modules/cjs/helpers:102:18)
at Object. (/Users/zzz/Develop/my-app/node_modules/postcss-safe-parser/lib/safe-parser.js:1:17) {
code: 'ERR_PACKAGE_PATH_NOT_EXPORTED'
}
hello,
I 'am using Node.js v17.0.1 and upgrading my package helped me solved this issue without downgrading the node version.
"yarn upgrade"
hope this will help waiting for the fix.
Reacted by mdubsmux, Matthew Danics, Lorenzo, yeongeun-kim-hyperlounge-ai, andreiwrk, AnaStepanovic, Zuz, Chad Ruble, Konrad Reiche, Daniel Garcia Medina and 13 more
Reacted by Konrad Reiche, Sumithran, Chukwuemeka Mba, Pecunians, savanpansuriya10 and Samuel Ferreira
Reacted by Vandanashree, Chukwuemeka Mba, Pecunians and Samuel Ferreira
yeah, I think when we install react, it installs on the latest version, but the yarn was not updated to that version that supports the version of react. "yarn upgrade" fixed the bug because it upgrades packages to their latest version.
If you got a message saying you will no longer receive security fixes if you do not upgrade when running yarn start or npm start then the solution is to run yarn upgrade, this will update the yarn packages and resolve this issue.
[1] ''react-scripts' is not recognized as an internal or external command,
[1] operable program or batch file.
[1] 'react-scripts exited with code 1
--> Sending SIGTERM to other processes..
[watch:css] npm run watch:css exited with code 1
Activity
Yochyo commentedon Oct 29, 2021
Can be temporarely fixed by downgrading to 16.13.0
[-]npm start failed[/-][+]npm start failed (code: 'ERR_PACKAGE_PATH_NOT_EXPORTED')[/+]AnthonyPoschen commentedon Nov 6, 2021
for anyone on mac needing the above temp fix which worked for me.
brew install node@16Ueland commentedon Nov 11, 2021
The "temp fix" is now two weeks old, any better fix out there yet?
Lionprincipe commentedon Nov 12, 2021
hello,
I 'am using Node.js v17.0.1 and upgrading my package helped me solved this issue without downgrading the node version.
hope this will help waiting for the fix.
ptrtorain commentedon Nov 13, 2021
cmd > npm i node@16. Now I can launch node@17. Looks like something missing in a clean node@17
Ansub commentedon Dec 1, 2021
"yarn upgrade"fixed the bug for me, and React App started working.
aeskafi commentedon Dec 1, 2021
"yarn upgrade"
fixed the bug for me, and everything works perfectly.
kedbirhan commentedon Dec 4, 2021
why is this error being thrown though, is it because of dependencies incompatibility ??
Ansub commentedon Dec 4, 2021
yeah, I think when we install react, it installs on the latest version, but the yarn was not updated to that version that supports the version of react. "yarn upgrade" fixed the bug because it upgrades packages to their latest version.
nlintas commentedon Dec 5, 2021
If you got a message saying you will no longer receive security fixes if you do not upgrade when running
yarn startornpm startthen the solution is to runyarn upgrade, this will update the yarn packages and resolve this issue.Bazmundi commentedon Dec 5, 2021
Looking to learn react so, basically upgraded my nodejs and npm and went for an
npx create-react-appfollowing the destructions at: https://reactjs.org/docs/create-a-new-react-app.htmlThat is:
Running on Windows 10, Node.js v17.2.0, npm/npx comes up as 8.2.0.
As I had not previously installed react, the npx command line above kindly pulled that in.
So, changed directory into my-app thence
npm startleft the insult at: https://pastebin.com/czGkpX1KLucked into this bug report. Ran
yarn updatethanks. Changes the insult to the following insult: https://pastebin.com/Zdchie2bSo, steps:
What fixed it for me was remover nodejs 17.2.0 and install 16.13.1 thanks.
YousefAlsbaihi commentedon Dec 14, 2021
This worked for me on
zzz6519003 commentedon Dec 14, 2021
but, need to yarn upgrade every time
jhkcia commentedon Dec 27, 2021
Fixed by running
npm upgradeananshe commentedon Jan 26, 2022
Awesome! That was easy fix, THANKS TO YOU!
timothymureithi commentedon Sep 24, 2022
"start": "react-scripts --openssl-legacy-provider start",
"build": "react-scripts --openssl-legacy-provider build"
That worked for me
xtRAVEN commentedon Dec 2, 2022
"start": "react-scripts --openssl-legacy-provider start",
"build": "react-scripts --openssl-legacy-provider build"
that worked for me x2
thanks @timothymureithi
HeyKalangi commentedon Jul 15, 2023
OpenSourceHelpCommunity/Questions#337
needed some help..
Achal9099 commentedon Jul 29, 2024
Error:
npm start
[1] ''react-scripts' is not recognized as an internal or external command,
[1] operable program or batch file.
[1] 'react-scripts exited with code 1
--> Sending SIGTERM to other processes..
[watch:css] npm run watch:css exited with code 1
package.json content
"scripts": {
"start": "npm run build:css && concurrently --kill-others 'npm:watch:css' 'react-scripts --openssl-legacy-provider start'",
"build": "npm run build:css && react-scripts --openssl-legacy-provider build",
"build:js": "react-scripts --openssl-legacy-provider build",
"test": "react-scripts test",
"test:all": "react-scripts test --watchAll=false",
"test:coverage": "react-scripts test --coverage --watchAll",
"test:debug": "react-scripts --inspect-brk test --runInBand --no-cache",
"eject": "react-scripts eject",
"prettier:base": "prettier 'src/**/*.{js,jsx,ts,tsx,json,css,scss,md}'",
"prettier:check": "yarn prettier:base --check",
"prettier:fix": "yarn prettier:base --write",
"l
zzz6519003 commentedon Jul 29, 2024
Install 'react-scripts
I always think it’s bad to have it
Achal9099 commentedon Jul 29, 2024
its install
npm ls -g react-scripts
C:\Program Files\nodejs -> .
`-- react-scripts@5.0.1
PS C:\Users\AchalBhangreNational\IdeaProjects\nbi-spport-ui> npm ls react-scripts
nbi-spp-ui@7.12.0-SNAPSHOT C:\Users\AchalBhangreNational\IdeaProjects\nbi-spport-ui
+-- @storybook/preset-create-react-app@2.1.2
|
-- react-scripts@4.0.1 deduped-- react-scripts@4.0.1node -v
v18.20.4