-
Notifications
You must be signed in to change notification settings - Fork 8
/
index.ts
23 lines (21 loc) · 677 Bytes
/
index.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import { NgModule, ModuleWithProviders } from '@angular/core';
import {Trumbowyg} from "./src/trumbowyg.component";
import {TrumbowygService} from "./src/trumbowyg.service";
import {TrumbowygConfig} from "./src/trumbowyg.config";
import {LoadExternalFiles} from "./src/load-external-file.service";
@NgModule({
imports: [],
declarations: [ Trumbowyg ],
providers: [ LoadExternalFiles, TrumbowygService ],
exports: [ Trumbowyg ]
})
export class TrumbowygModule {
static forRoot(config: TrumbowygConfig): ModuleWithProviders {
return {
ngModule: TrumbowygModule,
providers: [
{ provide: TrumbowygConfig, useValue: config }
]
};
}
}