vue项目警告There are multiple modules with names that only differ in casing

时间:2023-03-09 02:33:33
vue项目警告There are multiple modules with names that only differ in casing

执行npm run dev后出现了警告提示:

warning  in ./src/components/Public/yearSelectCell.vue

There are multiple modules with names that only differ in casing.    //有多个模块同名仅大小写不同
This can lead to unexpected behavior when compiling on a filesystem with other case-semantic. //这可能导致在一些文件系统中产生不是预期的行为
Use equal casing. Compare these module identifiers: //使用唯一的写法,对比下面这些模块的标识符:
* F:\路径。。。。。。

问题在于大小写没有区分:

import yearSelectCell from "@/components/public/yearSelectCell" //年份选择

在linux下是严格区分大小写,而windows不区分。所以上面问题导致在服务器上打包失败,而修改过来后就ok啦!