mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-30 01:17:16 +00:00
refactor(babel-preset-app): remove babel-plugin-dynamic-import-node
(#6197)
This commit is contained in:
parent
09878cd6dc
commit
c436839a17
@ -11,8 +11,7 @@ module.exports = function (api) {
|
|||||||
node: 'current'
|
node: 'current'
|
||||||
}
|
}
|
||||||
}]
|
}]
|
||||||
],
|
]
|
||||||
plugins: ['dynamic-import-node']
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return {}
|
return {}
|
||||||
|
@ -37,7 +37,6 @@
|
|||||||
"@vue/test-utils": "^1.0.0-beta.29",
|
"@vue/test-utils": "^1.0.0-beta.29",
|
||||||
"babel-eslint": "^10.0.2",
|
"babel-eslint": "^10.0.2",
|
||||||
"babel-jest": "^24.8.0",
|
"babel-jest": "^24.8.0",
|
||||||
"babel-plugin-dynamic-import-node": "^2.3.0",
|
|
||||||
"cheerio": "^1.0.0-rc.3",
|
"cheerio": "^1.0.0-rc.3",
|
||||||
"codecov": "^3.5.0",
|
"codecov": "^3.5.0",
|
||||||
"consola": "^2.10.0",
|
"consola": "^2.10.0",
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
This is the default preset used by Nuxt, which is mainly a wrapper around the `@babel/preset-env` preset. It also optionally uses the `@vue/babel-preset-jsx` preset as well as `@babel/plugin-syntax-dynamic-import`, `@babel/plugin-proposal-decorators`, `@babel/plugin-proposal-class-properties`, `@babel/plugin-transform-runtime`. Furthermore the preset is adding polyfills.
|
This is the default preset used by Nuxt, which is mainly a wrapper around the `@babel/preset-env` preset. It also optionally uses the `@vue/babel-preset-jsx` preset as well as `@babel/plugin-proposal-decorators`, `@babel/plugin-proposal-class-properties`, `@babel/plugin-transform-runtime`. Furthermore the preset is adding polyfills.
|
||||||
|
|
||||||
**Note**: Since `core-js@2` and `core-js@3` are both supported from Babel 7.4.0, we recommend directly adding `core-js` and setting the version via the [`corejs`](#corejs) option.
|
**Note**: Since `core-js@2` and `core-js@3` are both supported from Babel 7.4.0, we recommend directly adding `core-js` and setting the version via the [`corejs`](#corejs) option.
|
||||||
|
|
||||||
|
@ -13,7 +13,6 @@
|
|||||||
"@babel/core": "^7.5.5",
|
"@babel/core": "^7.5.5",
|
||||||
"@babel/plugin-proposal-class-properties": "^7.5.5",
|
"@babel/plugin-proposal-class-properties": "^7.5.5",
|
||||||
"@babel/plugin-proposal-decorators": "^7.4.4",
|
"@babel/plugin-proposal-decorators": "^7.4.4",
|
||||||
"@babel/plugin-syntax-dynamic-import": "^7.2.0",
|
|
||||||
"@babel/plugin-transform-runtime": "^7.5.5",
|
"@babel/plugin-transform-runtime": "^7.5.5",
|
||||||
"@babel/preset-env": "^7.5.5",
|
"@babel/preset-env": "^7.5.5",
|
||||||
"@babel/runtime": "^7.5.5",
|
"@babel/runtime": "^7.5.5",
|
||||||
|
@ -120,7 +120,6 @@ module.exports = (context, options = {}) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
plugins.push(
|
plugins.push(
|
||||||
require('@babel/plugin-syntax-dynamic-import'),
|
|
||||||
[require('@babel/plugin-proposal-decorators'), {
|
[require('@babel/plugin-proposal-decorators'), {
|
||||||
decoratorsBeforeExport,
|
decoratorsBeforeExport,
|
||||||
legacy: decoratorsLegacy !== false
|
legacy: decoratorsLegacy !== false
|
||||||
|
Loading…
Reference in New Issue
Block a user