Skip to content

Instantly share code, notes, and snippets.

@NiGhTTraX
Created April 4, 2021 11:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save NiGhTTraX/c66dc86e24048acb407ff52bdf5897c8 to your computer and use it in GitHub Desktop.
Save NiGhTTraX/c66dc86e24048acb407ff52bdf5897c8 to your computer and use it in GitHub Desktop.
module.exports = {
webpack: (config) => {
// Let Babel compile outside of src/.
const tsRule = config.module.rules.find(
(rule) => rule.test && rule.test.toString().includes("tsx|ts")
);
tsRule.include = undefined;
tsRule.exclude = /node_modules/;
return config;
},
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment