官术网_书友最值得收藏!

Component encapsulation

Angular components need more explicit configuration and some (in some cases confusing) characters in the template. You can put the template in a separate file, or for simpler components, you can include the template inline:

/* product-list.component.ts */
@Component({
    selector: 'product-list',
    template: `<p><product-detail *ngFor="let thing of things" [product]="product" /></p>`
})
export class ProductList {
    public products: Product[];
}
主站蜘蛛池模板: 荃湾区| 东乌珠穆沁旗| 南康市| 历史| 苗栗市| 泽州县| 道真| 龙海市| 东宁县| 云南省| 青神县| 温泉县| 凤山县| 宁海县| 海口市| 措勤县| 正定县| 白山市| 大同县| 中西区| 赤城县| 廊坊市| 伊吾县| 达日县| 育儿| 满洲里市| 高台县| 色达县| 萝北县| 左权县| 昌宁县| 杭锦旗| 衡水市| 鄱阳县| 忻城县| 平昌县| 平谷区| 子长县| 琼中| 北票市| 荆州市|