Skip to content

Commit 56b4ae5

Browse files
committed
use the correct dependency for babel-plugin-dynamic-import-node
1 parent f80d27b commit 56b4ae5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/babel-preset-react-app/create.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ module.exports = function(api, opts, env) {
158158
require('@babel/plugin-syntax-dynamic-import').default,
159159
isEnvTest &&
160160
// Transform dynamic import to require
161-
require('babel-plugin-transform-dynamic-import').default,
161+
require('babel-plugin-dynamic-import-node'),
162162
].filter(Boolean),
163163
};
164164
};

packages/babel-preset-react-app/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@
3131
"@babel/preset-react": "7.0.0",
3232
"@babel/runtime": "7.0.0",
3333
"babel-loader": "8.0.4",
34+
"babel-plugin-dynamic-import-node": "^2.2.0",
3435
"babel-plugin-macros": "2.4.2",
35-
"babel-plugin-transform-dynamic-import": "2.1.0",
3636
"babel-plugin-transform-react-remove-prop-types": "0.4.18"
3737
}
3838
}

0 commit comments

Comments
 (0)