小编Sri*_*nth的帖子

如何将ngx引导程序模块注入子模块-Angular 4

我的应用程序文件夹结构如下:

>app
  app.module.ts
  app.routing.ts
>>auth
  login.component
  auth.module.ts
  atuh.routing.module.ts
Run Code Online (Sandbox Code Playgroud)

现在,我想使用ngx-intl-input依赖于的模块ngx-bootstrap。我想包括intl-input在登录组件中。

所以,如果我进口ngx-bootsrapauth.module...

auth.module.ts

import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
import { LoginComponent } from './login/login.component';
import { AuthRoutingModule } from './auth-routing.module';
import { BsDropdownModule } from 'ngx-bootstrap/dropdown';
import { NgxIntlTelInputModule } from 'ngx-intl-tel-input';
@NgModule({
  imports: [
    CommonModule,
    AuthRoutingModule,
    BsDropdownModule.forRoot(),
    NgxIntlTelInputModule
  ],
  declarations: [LoginComponent]
})
export class AuthModule { }
Run Code Online (Sandbox Code Playgroud)

我收到以下错误:

ERROR Error: Uncaught (in promise): Error: …
Run Code Online (Sandbox Code Playgroud)

ng-bootstrap angular angular5

6
推荐指数
3
解决办法
5211
查看次数

标签 统计

angular ×1

angular5 ×1

ng-bootstrap ×1