Skip to content

Commit

Permalink
refactor: use babel.loadPartialConfigSync (added in babel 7.8)
Browse files Browse the repository at this point in the history
As planned in babel/babel#10746,
in babel 8 the old `loadPartialConfig` can't be used synchronously.
  • Loading branch information
sodatea committed Feb 3, 2020
1 parent 8028d9f commit 45b73d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/@vue/cli-plugin-babel/index.js
Expand Up @@ -26,7 +26,7 @@ module.exports = (api, options) => {
// there will be a VUE_CLI_TRANSPILE_BABEL_RUNTIME env var set.
// the `filename` field is required
// in case there're filename-related options like `ignore` in the user config
babel.loadPartialConfig({ filename: api.resolve('src/main.js') })
babel.loadPartialConfigSync({ filename: api.resolve('src/main.js') })

api.chainWebpack(webpackConfig => {
webpackConfig.resolveLoader.modules.prepend(path.join(__dirname, 'node_modules'))
Expand Down

0 comments on commit 45b73d1

Please sign in to comment.