AnthonyNahas / ngx-auth-firebaseui

Angular Material UI component for firebase authentication
https://ngx-auth-firebaseui.firebaseapp.com
MIT License
589 stars 165 forks source link

FR: Update for Angular 10 #566

Closed rhofour closed 2 years ago

rhofour commented 4 years ago

I tried using this project in an Angular 10 one and I'm getting the following error:

    node_modules/ngx-auth-firebaseui/lib/ngx-auth-firebaseui.module.d.ts:22:132 - error TS2314: Generic type 'ModuleWithProviders<T>' requires 1 type argument(s).

    22     static forRoot(configFactory: FirebaseAppConfig, appNameFactory?: () => string | undefined, config?: NgxAuthFirebaseUIConfig): ModuleWithProviders;

This appears to be related to ModuleWithProviders change in Angular 10.

I'm not sure what else is needed to make this compatible with Angular 10.

vella-nicholas commented 4 years ago

I fixed the issue by adding the following in packages.json

"scripts": {
    "postinstall": "ngcc"
  },

https://angular.io/guide/migration-module-with-providers https://angular.io/guide/glossary#ngcc https://angular.io/guide/glossary#ivy

If you use rxjs Subject you might encounter this issue. https://stackoverflow.com/questions/62812510/subject-instantiation-error-in-angular-10

dobromyslov commented 4 years ago

Tried to install it in the project with Angular 10 and fresh @angular/fire and got lots of inconsistent package errors.

npm WARN deprecated angularfire2@5.4.2: AngularFire has moved, we're now @angular/fire
npm WARN inquirer-autocomplete-prompt@1.0.2 requires a peer of inquirer@^5.0.0 || ^6.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/animations@5.2.11 requires a peer of @angular/core@5.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/flex-layout@2.0.0-rc.1 requires a peer of @angular/common@^2.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/flex-layout@2.0.0-rc.1 requires a peer of @angular/core@^2.2.3 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/flex-layout@2.0.0-rc.1 requires a peer of rxjs@^5.0.1 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/flex-layout@2.0.0-rc.1 requires a peer of zone.js@^0.7.2 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@5.2.5 requires a peer of @angular/core@>=5.0.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/material@5.2.5 requires a peer of @angular/common@>=5.0.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/cdk@5.2.5 requires a peer of @angular/core@>=5.0.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/cdk@5.2.5 requires a peer of @angular/common@>=5.0.0 <7.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/forms@5.2.11 requires a peer of rxjs@^5.5.0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/forms@5.2.11 requires a peer of @angular/core@5.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/forms@5.2.11 requires a peer of @angular/common@5.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/forms@5.2.11 requires a peer of @angular/platform-browser@5.2.11 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/fire@5.4.2 requires a peer of @angular/common@>=6.0.0 <9 || ^9.0.0-0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/fire@5.4.2 requires a peer of @angular/core@>=6.0.0 <9 || ^9.0.0-0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/fire@5.4.2 requires a peer of @angular/platform-browser@>=6.0.0 <9 || ^9.0.0-0 but none is installed. You must install peer dependencies yourself.
npm WARN @angular/fire@5.4.2 requires a peer of @angular/platform-browser-dynamic@>=6.0.0 <9 || ^9.0.0-0 but none is installed. You must install peer dependencies yourself.

Looks like ngx-auth-firebaseui should be improved to be compatible with Angular 10.

Kamil7S commented 4 years ago

Any plans for upgrading to Angular 10 and new Material Design?

DavidTheProgrammer commented 3 years ago

The library is updated and now works with V11 of Angular. Can we go ahead and mark this as resolved? @AnthonyNahas