当我在我的 Angular 4 应用程序中运行 ng build -prod 时出现错误,它说
“模块'AppModule导入的Y:/example/node_modules/angular-2-data-table/dist/index.d.ts中的意外值'DataTableModule中的错误。请添加@NgModule注释。”
这是 index.d.ts 文件
import { DataTable } from './components/table.component';
import { DataTableColumn } from './components/column.component';
import { DataTableRow } from './components/row.component';
import { DataTablePagination } from './components/pagination.component';
import { DataTableHeader } from './components/header.component';
export * from './components/types';
export * from './tools/data-table-resource';
export { DataTable, DataTableColumn, DataTableRow, DataTablePagination,
DataTableHeader };
export declare const DATA_TABLE_DIRECTIVES: (typeof DataTable | typeof
DataTableColumn)[];
export declare class DataTableModule {
}
我怎样才能解决这个问题?
注意:我还是 Angular 的新手,这不是我的模块,我使用这个包 https://github.com/ggmod/angular-2-data-table
谢谢