1

In our project, we are using monorepo and we had to use react-app-rewired to customize some of the webpack configs without ejecting.

Now I am getting 3 deprecation warnings and I can't find anything related to them in the code. I assume that these are baried somewhere in CRA internal.

enter image description here

Also inspected the config object in config-overload.js. Didn't find anything even remotely related to these deprecations.

module.exports = function override(config, env) {
  // Remove the ModuleScopePlugin which throws when we try to import something
  // outside of src/.
  config.resolve.plugins.pop();

  // Let Babel compile outside of src/.
  // console.error('tsRule ', config);
  // exit();
  const tsRule = config.module.rules[1].oneOf[3];
  tsRule.include = undefined;
  tsRule.exclude = /node_modules/;

  return config;
}

How can I resolve these?

Another note: we also upgraded node to the latest (17). Not sure is that related.

Shurik Agulyansky
  • 2,607
  • 2
  • 34
  • 76

0 Answers0