We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
按照图中顺序配置之后,打包提示 需要安装 @vue/babel-preset-app 安装之后打包又提示 当去掉项目里手动引入之后,同时提示
@vue/babel-preset-app
最后查了一下资料发现 直接安装,然后新建 babel.config.js 文件之后,需要配置
babel.config.js
module.exports = { presets: [["@babel/preset-env", { useBuiltIns: "entry", "corejs": 3 }] ] }
这里的 @babel/preset-env 跟楼主配置的不一样,我不太懂,不过这样配置之后,打包没有报错了
@babel/preset-env
The text was updated successfully, but these errors were encountered:
@babel/polyfill 已经弃用,需要在入口文件引入import 'core-js/stable'; import 'regenerator-runtime/runtime'; 官方文档已经给出,作者还没修改吧
import 'core-js/stable'; import 'regenerator-runtime/runtime';
Sorry, something went wrong.
@ babel / polyfill已经弃用,需要在入口文件约会import 'core-js/stable'; import 'regenerator-runtime/runtime'; 官方文档已经命名,作者还没修改吧
这个我加上了
import "@babel/polyfill"; import "core-js/stable"; import "regenerator-runtime/runtime";
之所以加上 @babel/polyfill 是因为还是有一些语法 core-js/stable 跟 regenerator-runtime/runtime 解析不了的
@babel/polyfill
core-js/stable
regenerator-runtime/runtime
No branches or pull requests
按照图中顺序配置之后,打包提示 需要安装
@vue/babel-preset-app
安装之后打包又提示当去掉项目里手动引入之后,同时提示
最后查了一下资料发现 直接安装,然后新建
babel.config.js
文件之后,需要配置这里的
@babel/preset-env
跟楼主配置的不一样,我不太懂,不过这样配置之后,打包没有报错了The text was updated successfully, but these errors were encountered: