I want to create input field in angular, it is customized:
<cs-input [field]="inputname" formControlName="inputname"></cs-input>
the .ts file has declaration:
reactiveFormGroup = this.fb.group({
fname: ['', Validators.required],
sname: '',
selectData: '',
inputname: ''
})
and inputField is:
inputname: InputField = {
uniqueFormKey: "inputname",
type: InputTypeEnum.text,
id: "inputname"
}
and i get error:
ERROR NullInjectorError: R3InjectorError(AppModule)[InjectionToken ngx-mask config -> InjectionToken ngx-mask config -> InjectionToken ngx-mask config]:
NullInjectorError: No provider for InjectionToken ngx-mask config!
In angular app.module.ts i have declarations:
imports: [
BrowserModule,
FormsModule,
ReactiveFormsModule,
NgxMaskModule.forRoot(),
NgbModule,
],
and i've exported config:
export const config: InjectionToken<any> = new InjectionToken('ngxmask config');
Can you help me? What i'm ding wrong?