Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Angular 13 build error #33

Closed
joergbaier opened this issue Jan 17, 2022 · 3 comments
Closed

Angular 13 build error #33

joergbaier opened this issue Jan 17, 2022 · 3 comments

Comments

@joergbaier
Copy link

The npm update over the weekend did not resolve the build errors for angular 13

Error: node_modules/@ngbmodule/material-carousel/lib/carousel.module.d.ts:2:10 - error TS2305: Module '"@angular/compiler/src/core"' has no exported member 'ModuleWithProviders'.

2 import { ModuleWithProviders } from '@angular/compiler/src/core';
@jnfaerch
Copy link

carousel.module.ts should be

...
export class MatCarouselModule {
  static forRoot(): ModuleWithProviders<MatCarouselModule> {
    return {
      ngModule: MatCarouselModule,
      providers: [
        { provide: HAMMER_GESTURE_CONFIG, useClass: MatCarouselHammerConfig }
      ]
    };
  }
}

According to https://angular.io/guide/migration-module-with-providers

@myrddraall
Copy link

ModuleWithProviders should also be imported from '@angular/core' and not '@angular/compiler/src/core'

@joergbaier
Copy link
Author

dead repo

@joergbaier joergbaier closed this as not planned Won't fix, can't repro, duplicate, stale Aug 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants