angular2抽取公共复用组件(模块间公用)
例如创建footer组件
- ng g c footer –module
- footer.component.spec.ts (测试文件)
- *footer.component.ts (ts组件文件)
-footer.module.ts (模块文件)
具体代码
footer.component.ts
代码块
import { Router } from '@angular/router';
@Component({
selector: 'app-footer',
template: `
<div class="row login_footer"