Skip to content
New issue

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

webpack搭建的项目在webpack.config.js中,babel-loader下增加sourceType: 'unambiguous',并没有解决 #4

Open
liujiufa opened this issue Jun 13, 2024 · 1 comment

Comments

@liujiufa
Copy link

使用react-cli创建的项目,在注册Provider组件时出现截图报错。
image

@myZhangDong
Copy link
Collaborator

在你的webpack.config 中增加这个配置看是否有效 module: {
rules: [
...
{
test: /.mjs$/,
resolve: {
fullySpecified: false
},
include: /node_modules/,
type: "javascript/auto"
}
]
},

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants