Skip to content

Commit

Permalink
Switch back to babel-loader (facebook#5143)
Browse files Browse the repository at this point in the history
* Switch back to babel-loader

* Preserve existing caller options. Use Object.assign instead of object spread.

* Updated filename in package.json

* Update comment about cache identifier

* Update macro check to use a regex

* Move macro check regex out of function
  • Loading branch information
iansu authored and Timer committed Sep 27, 2018
1 parent 0764c47 commit 6e97c1a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 6 deletions.
8 changes: 4 additions & 4 deletions config/webpack.config.dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -218,11 +218,11 @@ module.exports = {
},
},
{
// 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'),
loader: require.resolve('babel-loader'),
options: {
customize: require.resolve(
'babel-preset-react-app/webpack-overrides'
),
// @remove-on-eject-begin
babelrc: false,
configFile: 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 @@ -272,8 +272,11 @@ module.exports = {
// 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'),
loader: require.resolve('babel-loader'),
options: {
customize: require.resolve(
'babel-preset-react-app/webpack-overrides'
),
// @remove-on-eject-begin
babelrc: false,
configFile: false,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"babel-core": "7.0.0-bridge.0",
"babel-eslint": "9.0.0",
"babel-jest": "23.6.0",
"babel-loader": "8.0.2",
"babel-loader": "8.0.4",
"babel-plugin-named-asset-import": "^0.2.0",
"babel-preset-react-app": "^4.0.0",
"bfj": "6.1.1",
Expand Down

0 comments on commit 6e97c1a

Please sign in to comment.