仅某些Vue项目中的mini-css-extract-plugin冲突错误

问题描述

在两个Vue项目上,我从build上的mini-css-extract-plugin收到顺序冲突的警告。这是其中一种警告的示例:

Conflicting order. Following module has been added:
 * css ./node_modules/css-loader/dist/cjs.js??ref--6-oneOf-3-1!./node_modules/postcss-loader/src??ref--6-oneOf-3-2!./node_modules/vue2-datepicker/index.css
despite it was not able to fulfill desired ordering with these modules:
 * css ./node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!./node_modules/vue-loader/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/src??ref--8-oneOf-1-2!./node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!./node_modules/cache-loader/dist/cjs.js??ref--0-0!./node_modules/vue-loader/lib??vue-loader-options!./src/components/global/simple-button.vue?vue&type=style&index=0&id=79cc5fd2&lang=scss&scoped=true&
   - couldn't fulfill desired order of chunk group(s) leads
   - while fulfilling desired order of chunk group(s) lead-panel

我了解这是由于整个项目中组件的导入顺序相互矛盾(在此处https://github.com/vuejs/vue-cli/issues/3771#issuecomment-481072017mini-css-extract-plugin WARNING in chunk chunkName [mini-css-extract-plugin] Conflicting order between:进行解释)。

我已经绘制了导入树,可以看到冲突。我也知道我可以禁用该警告。

我不明白的是为什么我只在两个Vue项目上看到这个,而在其他几个项目上却看不到。我尝试过在其他项目中复制错误,但是没有运气。

我检查了软件包的版本,它们似乎匹配。特别是,我查看了mini-css-extract-plugin本身的版本。项目使用0.8.0或0.9.0,这两个版本的AFAIK都应显示警告。这些项目的布局都非常相似。

有什么主意,为什么我会在某些项目上看到此警告,而在其他项目上看不到该警告?

解决方法

暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!

如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。

小编邮箱:dio#foxmail.com (将#修改为@)

相关问答

错误1:Request method ‘DELETE‘ not supported 错误还原:...
错误1:启动docker镜像时报错:Error response from daemon:...
错误1:private field ‘xxx‘ is never assigned 按Alt...
报错如下,通过源不能下载,最后警告pip需升级版本 Requirem...