英文:
Already included the file name.....?
问题
ERROR
src/app/app.module.ts:7:35 - error TS1149: 文件名 'E:/Angular Project/hamza-todo-list/src/app/MyComponents/todo-item/todo-item.component.ts' 与已包括的文件名 'E:/Angular Project/hamza-todo-list/src/app/MYComponents/todo-item/todo-item.component.ts' 仅在大小写方面有所不同。
该文件包含在程序中,原因是:
通过文件 'E:/Angular Project/hamza-todo-list/src/app/MYComponents/todos/todos.component.ngtypecheck.ts' 从 '../todo-item/todo-item.component' 导入
通过文件 'E:/Angular Project/hamza-todo-list/src/app/MYComponents/todo-item/todo-item.component.ngtypecheck.ts' 从 './todo-item.component' 导入
通过文件 'E:/Angular Project/hamza-todo-list/src/app/app.module.ts' 从 './MyComponents/todo-item/todo-item.component' 导入
7 import { TodoItemComponent } from './MyComponents/todo-item/todo-item.component';
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/app/MYComponents/todos/todos.component.ngtypecheck.ts:4:21
4 import * as i3 from '../todo-item/todo-item.component';
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
通过导入在此处包括文件。
src/app/MYComponents/todo-item/todo-item.component.ngtypecheck.ts:1:21
1 import * as i0 from './todo-item.component';
~~~~~~~~~~~~~~~~~~~~~~~
通过导入在此处包括文件。
各位,我是新手程序员...不知道这个错误是什么意思?
英文:
Compiled with problems:X
ERROR
src/app/app.module.ts:7:35 - error TS1149: File name 'E:/Angular Project/hamza-todo-list/src/app/MyComponents/todo-item/todo-item.component.ts' differs from already included file name 'E:/Angular Project/hamza-todo-list/src/app/MYComponents/todo-item/todo-item.component.ts' only in casing.
The file is in the program because:
Imported via '../todo-item/todo-item.component' from file 'E:/Angular Project/hamza-todo-list/src/app/MYComponents/todos/todos.component.ngtypecheck.ts'
Imported via './todo-item.component' from file 'E:/Angular Project/hamza-todo-list/src/app/MYComponents/todo-item/todo-item.component.ngtypecheck.ts'
Imported via './MyComponents/todo-item/todo-item.component' from file 'E:/Angular Project/hamza-todo-list/src/app/app.module.ts'
7 import { TodoItemComponent } from './MyComponents/todo-item/todo-item.component';
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
src/app/MYComponents/todos/todos.component.ngtypecheck.ts:4:21
4 import * as i3 from '../todo-item/todo-item.component';
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
File is included via import here.
src/app/MYComponents/todo-item/todo-item.component.ngtypecheck.ts:1:21
1 import * as i0 from './todo-item.component';
~~~~~~~~~~~~~~~~~~~~~~~
File is included via import here.
Guys i'm new programing...don't know what this error is about???
答案1
得分: 0
你的两个导入大小写不一致...
MyComponents/todo-item/todo-item.component.ts
和
MYComponents/todo-item/todo-item.component.ts
^-----
(注意大写的 'Y')
英文:
Your two imports differ in case...
MyComponents/todo-item/todo-item.component.ts
and
MYComponents/todo-item/todo-item.component.ts
^-----
(note the uppercase 'Y')
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论