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
index.js:8 Uncaught ReferenceError: process is not defined
at Object../node_modules/chalk/index.js (index.js:8)
at __webpack_require__ (bootstrap:734)
at fn (bootstrap:100)
at Object../node_modules/react-dev-utils/formatWebpackMessages.js (formatWebpackMessages.js:10)
at __webpack_require__ (bootstrap:734)
at fn (bootstrap:100)
at Object../node_modules/@pmmmwh/react-refresh-webpack-plugin/src/runtime/ErrorOverlayEntry.js (ErrorOverlayEntry.js:5)
at __webpack_require__ (bootstrap:734)
at fn (bootstrap:100)
at Object.0 (index.tsx:12)
It's caused by a deep dependency of my app, but I deduced the right place to correct this may be here.
I'm not using CRA directly, and running this in an electron app that has sandboxed access to a subset of nodejs API.
Environment
react-dev-utils9.1.0; master in the repo currently has the same behavior.
webpack 4, babel 7 and so on, but this is irrelevant as workarounds won't cover my use case.
Expected behavior
I expect react-dev-utils/formatWebpackMessages.js to not use chalk, since it's not used in the cli context. chalk requires Node APIs to be available.
Actual behavior
I got an exception. cause chalk has const isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm');. It's not adopted for browser use.
Reproducible demo
Sorry.
The text was updated successfully, but these errors were encountered:
This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs.
Describe the bug
I have an error below:
It's caused by a deep dependency of my app, but I deduced the right place to correct this may be here.
I'm not using CRA directly, and running this in an electron app that has sandboxed access to a subset of nodejs API.
Environment
react-dev-utils
9.1.0
;master
in the repo currently has the same behavior.webpack
4,babel
7 and so on, but this is irrelevant as workarounds won't cover my use case.Expected behavior
I expect
react-dev-utils/formatWebpackMessages.js
to not usechalk
, since it's not used in the cli context.chalk
requires Node APIs to be available.Actual behavior
I got an exception. cause
chalk
hasconst isSimpleWindowsTerm = process.platform === 'win32' && !(process.env.TERM || '').toLowerCase().startsWith('xterm');
. It's not adopted for browser use.Reproducible demo
Sorry.
The text was updated successfully, but these errors were encountered: