Skip to content

Commit

Permalink
Prevent the cache of files using Babel Macros (facebook#5078)
Browse files Browse the repository at this point in the history
* Add new overrides option

* Add file to package.json

* Create our own loader

* Remove overrides

* We have to use a real babel option

* Add comments
  • Loading branch information
Timer authored Sep 25, 2018
1 parent 2127f4a commit 87fb78b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion config/webpack.config.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,10 @@ module.exports = {
},
},
{
loader: require.resolve('babel-loader'),
// We need to use our own loader until `babel-loader` supports
// customization
// https://github.com/babel/babel-loader/pull/687
loader: require.resolve('babel-preset-react-app/loader'),
options: {
// @remove-on-eject-begin
babelrc: false,
Expand Down
5 changes: 4 additions & 1 deletion config/webpack.config.prod.js
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,10 @@ module.exports = {
// improves compile time on larger projects
require.resolve('thread-loader'),
{
loader: require.resolve('babel-loader'),
// We need to use our own loader until `babel-loader` supports
// customization
// https://github.com/babel/babel-loader/pull/687
loader: require.resolve('babel-preset-react-app/loader'),
options: {
// @remove-on-eject-begin
babelrc: false,
Expand Down

0 comments on commit 87fb78b

Please sign in to comment.