【发布时间】:2018-12-10 18:40:54
【问题描述】:
在创建模块时,我们可以在 Angular CLI 中添加 --routing-scope 作为参数。
ng g m dashboard --routing-scope something-here --routing
使用此命令时出现错误:
Schematic input does not validate against the
Schema: {"routingScope":"dashboard","routing":false,"spec":true,"flat":false,"commonModule":true}
Errors: Data path ".routingScope" should be equal to one of the allowed values.
但是允许的值是多少?
文档中没有描述这个参数。
【问题讨论】:
-
也许可以查看文档
-
@Li357 文档中没有描述
-
@Tukkan,这里提到了他们:github.com/angular/angular-cli/wiki/generate-module
-
@CruelEngine 是但“生成路由的范围。”是写的所有内容以及我可以从参数名称中推断出的内容,但仍不完全清楚。它是主要生根配置中的根名称还是不同的名称?我尝试了多个值和组合,它们都返回上述错误。
标签: angular angular-cli angular-cli-v6