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

同一个项目中,既包含了全量引入,又包含了按需引入,然后有如下报错,请教下如何解决? #64

Open
mexhfl opened this issue Jun 8, 2022 · 1 comment

Comments

@mexhfl
Copy link

mexhfl commented Jun 8, 2022

error in ./src_form/main.js

Syntax Error: Error: D:\Project\jc_forms_git\src_form\main.js: [babel-plugin-component] If you are using bothon-demand and importing all, make sure to invoke the importing all first.
at Array.map ()

@ multi (webpack)-dev-server/client?http://192.168.1.208:8080/sockjs-node (webpack)/hot/dev-server.js ./src_form/main.js

error in ./src_report/main.js

Syntax Error: Error: D:\Project\jc_forms_git\src_report\main.js: [babel-plugin-component] If you are using bothon-demand and importing all, make sure to invoke the importing all first.
at Array.map ()

@ multi (webpack)-dev-server/client?http://192.168.1.208:8080/sockjs-node (webpack)/hot/dev-server.js ./src_report/main.js

error in ./src_todo/main.js

Syntax Error: Error: D:\Project\jc_forms_git\src_todo\main.js: [babel-plugin-component] If you are using bothon-demand and importing all, make sure to invoke the importing all first.
at Array.map ()

@ multi (webpack)-dev-server/client?http://192.168.1.208:8080/sockjs-node (webpack)/hot/dev-server.js ./src_todo/main.js

@purer01
Copy link

purer01 commented Dec 17, 2023

按照babel-plugin-component给出的提示,如果既有全局又有按需引入的话,你应该先全局引入,再按需引入。

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

No branches or pull requests

2 participants