解决ERROR in Conflict: Multiple assets emit different content to the same filename index.html 的问题

简介: 解决ERROR in Conflict: Multiple assets emit different content to the same filename index.html 的问题

一、所遇问题简述:


1、问题描述:


在用 vue-cli 正常来创建新的基于 vue2 框架 的项目,在安装好 node-modules 之后,运行命令 ‘npm run serve’ ,报错情况如下:


ERROR in Conflict:Multiple assets emit different content to the same filename index.html

冲突中的错误:多个资产向相同的文件名 index.html 发出不同的内容


2、问题分析:


其一、创建项目的过程及命令是没有问题的,基于 vue2 框架的版本也没有问题,可以考虑是在创建项目中出现了中文名字的原因(因为此项目的上一层我用的是汉字)?


其二、文件的配置问题,在脚手架进行创建项目的时候,有关多个文件名重名了(报错是 index.html 文件发生冲突了)?


二、解决问题的方案:


1、方案一、尝试用纯英文命名,避免中文命名的影响(成功解决了问题);


三、方案一的实施过程(即:将中文文件名修改为纯英文文件名,注意也不要括号等符号):


1、报错项目存在的问题:


该项目文件的上一层命名 存在中文文字;


2、问题的解决过程:


将该项目文件名称及该项目文件的上一层 命名为纯英文,此时发现再运行该项目后,能成功运行


3、该方法是解决该问题的根本办法


只有命名不包含中文,是不会在用 vue-cli 创建项目的时候报出该错误的;

目录
相关文章
|
5月前
解决ERROR in Conflict: Multiple assets emit different content to the same filename index.html 的问题
解决ERROR in Conflict: Multiple assets emit different content to the same filename index.html 的问题
296 1
|
3月前
解决ERROR in Conflict: Multiple assets emit different content to the same filename index.html 的问题
解决ERROR in Conflict: Multiple assets emit different content to the same filename index.html 的问题
174 0
|
10月前
报错 An error happened during template parsing (template: “ServletContext resource [/shiroTest.html]“)
报错 An error happened during template parsing (template: “ServletContext resource [/shiroTest.html]“)
sublime 打开报错 Error loading syntax file “Packages/HTML/HTML.sublime-syntax“: Apparent recursion withi
卸载步骤 打开sublime工具,按shift+command+p,打开输入框 输入remove package 输入 JavaScriptNext-ES6 Syntax,找到此插件,选中,enter卸载 重启sublime,弹出框消失
429 0
|
关系型数据库 MySQL 应用服务中间件
linux篇-Parse error: syntax error, unexpected ‘new’ (T_NEW) in /usr/local/nginx/html/cacti/lib/adodb
linux篇-Parse error: syntax error, unexpected ‘new’ (T_NEW) in /usr/local/nginx/html/cacti/lib/adodb
134 0
linux篇-Parse error: syntax error, unexpected ‘new’ (T_NEW) in /usr/local/nginx/html/cacti/lib/adodb
|
移动开发 JavaScript 前端开发
[译]HTML进阶之Content categories
[译]HTML进阶之Content categories
[译]HTML进阶之Content categories
|
消息中间件
https://geewu.gitbooks.io/rabbitmq-quick/content/RabbitMQ%E5%9F%BA%E7%A1%80%E6%93%8D%E4%BD%9C.html
https://geewu.gitbooks.io/rabbitmq-quick/content/RabbitMQ%E5%9F%BA%E7%A1%80%E6%93%8D%E4%BD%9C.html
1130 0
|
20天前
|
前端开发 JavaScript 开发工具
【HTML/CSS】入门导学篇
【HTML/CSS】入门导学篇
23 0
|
22天前
|
JavaScript 前端开发
【快捷键配置】常用HTML类名、CSS样式名称、JS方法变量名、vue代码片段
【快捷键配置】常用HTML类名、CSS样式名称、JS方法变量名、vue代码片段
|
1天前
|
前端开发 容器
用html、css实现一颗简单小爱心【2022首文】
用html、css实现一颗简单小爱心【2022首文】