小编ali*_*lah的帖子

如何找到哪些组件存在冲突?

我正在使用Angular 2的ES5风格.我遇到了这个错误:

Unhandled Promise rejection: Template parse errors:
More than one component matched on this element.
Make sure that only one component's selector can match a given element.
Conflicting components: class2,class6 ("
    </tbody>
</table>
[ERROR ->]<paging [data]="data" (changed)="loadCountries($event)" unit="country"></paging>
<md-spinner class="lis"): class18@30:0 ; Zone: <root> ; Task: Promise.then ; Value: 
Run Code Online (Sandbox Code Playgroud)

它说class2class6.我找不到类的原始名称.

这是我的模块定义:

var module = ng.core.NgModule({
    imports: [
        ng.platformBrowser.BrowserModule, 
        ng.router.RouterModule.forRoot([].concat([...])), 
        ng.material.MaterialModule, 
        ng.http.HttpModule, 
        ng.common.CommonModule, 
        ng.forms.FormsModule],
    declarations: [
        app.CoalAddWorldCoalSupply, 
        app.FilterValuesDialog, 
        app.CoalFlows, 
        app.ImportWorldCoalSupplies, 
        app.CoalProducts, 
        app.CoalReports, 
        app.CoalUpsertFlow, 
        app.CoalUpsertProduct, 
        app.CoalWorldCoalSupplies, 
        app.CountryList, …
Run Code Online (Sandbox Code Playgroud)

angular

8
推荐指数
1
解决办法
9711
查看次数

标签 统计

angular ×1