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

Documentation missing for setting up with Angular 19 in pure standalone mode #245

Open
NealGooch opened this issue Feb 17, 2025 · 1 comment

Comments

@NealGooch
Copy link

NealGooch commented Feb 17, 2025

I have used ngx-permissions in several apps but have recently started to use Angular 19 in pure standalone mode.

It wasn't clear where "NgxPermissionsModule.forRoot()" should go in this setup.

To help others it would be useful if the following sample could be added to the docs/wiki - it is sort of obvious once you know but it had me puzzled for some time!

Update app.config.ts

import {
  ApplicationConfig,
  importProvidersFrom,
  provideZoneChangeDetection,
} from '@angular/core';
import { NgxPermissionsModule } from 'ngx-permissions';

export const appConfig: ApplicationConfig = {
  providers: [
    provideZoneChangeDetection({ eventCoalescing: true }),
    provideHttpClient(),
    provideRouter(routes),
    provideAnimationsAsync(),
    importProvidersFrom(NgxPermissionsModule.forRoot()),
  ],
};
@AlexKhymenko
Copy link
Owner

@NealGooch Thank You. Will add to wiki during the week.

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

2 participants