redux-devtools-inspector icon indicating copy to clipboard operation
redux-devtools-inspector copied to clipboard

Critical dependency: the request of a dependency is an expression

Open mkg0 opened this issue 7 years ago • 4 comments

getting these 2 warnings in webpack bundle:

WARNING in ../~/jsondiffpatch/src/main.js
56:20-50 Critical dependency: the request of a dependency is an expression

WARNING in ../~/jsondiffpatch/src/main.js
61:19-47 Critical dependency: the request of a dependency is an expression

mkg0 avatar Apr 03 '17 09:04 mkg0

+1. redux-devtools-log-monitor works fine, however.

"react": "^15.4.2",
"react-dom": "^15.4.2",
"redux-devtools": "^3.3.2",
"redux-devtools-inspector": "^0.11.3"

DevTools is launched in a pop-up. Currently looks like this: screen shot 2017-04-08 at 13 35 41

egorovli avatar Apr 08 '17 10:04 egorovli

That issue comes from jsondiffpatch package, due to an expression require statement! Webpack throws a warning Critical dependency: the request of a dependency is an expression when you require your dependency like,

  var packageInfoModuleName = '../package.json';
  var packageInfo = require(packageInfoModuleName);

Cause: jsondiffpatch/blob/master/src/main.js:56

P.S: Issue from jsondiffpatch

kderbalah avatar Aug 03 '17 15:08 kderbalah

Feel free to use this workaround in package.json until the PR is merged:

"redux-devtools-inspector": "cooperka/redux-devtools-inspector#cdb11f9fd2b118b62e249f9dd58329c1e8f9a639"

cooperka avatar Dec 10 '17 15:12 cooperka

The issue seems to be resolved in jsondiffpatch. See https://github.com/benjamine/jsondiffpatch/pull/204. Could you update the dependency to the current version 0.3.5?

trixn86 avatar Feb 26 '18 15:02 trixn86