首页
学习
活动
专区
工具
TVP
发布
社区首页 >问答首页 >Dart web教程重新生成应用程序组件时出现问题

Dart web教程重新生成应用程序组件时出现问题
EN

Stack Overflow用户
提问于 2018-09-24 20:42:42
回答 1查看 234关注 0票数 0

我正在尝试遵循此处的Dart Web教程https://webdev.dartlang.org/angular/tutorial/toh-pt5

为了确保我从正确的基础开始下载到H-4-master,模板从最后的chapter.It构建并运行良好,然后我按照指南移动和重命名应用程序组件,然后手动创建一个新的,但是在遵循“创建应用程序组件”之后,指南说明重新加载页面和应用程序应该可以工作,但是我得到了下面包含的错误。

它表明它没有正确地生成app_component.template文件,你知道如何调试它吗?

代码语言:javascript
复制
SEVERE] build_web_compilers|entrypoint on test/app_test.dart (cached):
Unable to find modules for some sources, this is usually the result of either a
bad import, a missing dependency in a package (or possibly a dev_dependency
needs to move to a real dependency), or a build failure (if importing a
generated file).

Please check the following imports:

import 'src/hero_list_component.template.dart' as _ref1; from angular_tour_of_heroes|lib/app_component.template.dart at 13:1

[SEVERE] build_web_compilers|entrypoint on web/main.dart (cached):
Unable to find modules for some sources, this is usually the result of either a
bad import, a missing dependency in a package (or possibly a dev_dependency
needs to move to a real dependency), or a build failure (if importing a
generated file).

Please check the following imports:

import 'src/hero_list_component.template.dart' as _ref1; from angular_tour_of_heroes|lib/app_component.template.dart at 13:1

[SEVERE] build_web_compilers|entrypoint on test/app_test.dart.browser_test.dart (cached):
Unable to find modules for some sources, this is usually the result of either a
bad import, a missing dependency in a package (or possibly a dev_dependency
needs to move to a real dependency), or a build failure (if importing a
generated file).

Please check the following imports:

import 'src/hero_list_component.template.dart' as _ref1; from angular_tour_of_heroes|lib/app_component.template.dart at 13:1

[SEVERE] Failed after 943ms
Serving web on http://localhost:8080
Serving test on http://localhost:8080
EN

回答 1

Stack Overflow用户

发布于 2018-09-26 08:06:02

您是否也重命名了组件文件?

如果是,则从其中包含该组件的文件生成template.dart文件。因此,它将遵循component.dart -> component.template.dart模式

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/52479690

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档