next-ucap-messenger/projects/ucap-webmessenger-api-prompt/src/lib/ucap-prompt-api.module.ts
leejinho abc1215d6c Call 기능 구현.
>> call api 호출 후 응답값에 대한 처리가 필요함. 현재 응답이 느려서 500 에러 떨어짐.
2019-12-16 17:42:49 +09:00

25 lines
596 B
TypeScript

import { NgModule, ModuleWithProviders } from '@angular/core';
import { _MODULE_CONFIG } from './config/token';
import { ModuleConfig } from './config/module-config';
import { CallService } from './services/call.service';
const SERVICES = [CallService];
@NgModule({
declarations: [],
imports: [],
exports: []
})
export class UCapPromptApiModule {
public static forRoot(
config: ModuleConfig
): ModuleWithProviders<UCapPromptApiModule> {
return {
ngModule: UCapPromptApiModule,
providers: [{ provide: _MODULE_CONFIG, useValue: config }, ...SERVICES]
};
}
}