How to use the angular-user-idle.UserIdleModule.forRoot function in angular-user-idle

To help you get started, we’ve selected a few angular-user-idle examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Ride-The-Lightning / RTL / src / app / app.module.ts View on Github external
import { AuthGuard } from './shared/services/auth.guard';
import { AuthInterceptor } from './shared/services/auth.interceptor';

import { RTLReducer } from './store/rtl.reducers';
import { RTLEffects } from './store/rtl.effects';
import { LNDEffects } from './lnd/store/lnd.effects';
import { CLEffects } from './clightning/store/cl.effects';

@NgModule({
  imports: [
    BrowserModule,
    BrowserAnimationsModule,
    SharedModule,
    PerfectScrollbarModule,
    routing,
    UserIdleModule.forRoot({idle: 60 * 60, timeout: 1, ping: null}),
    StoreModule.forRoot(RTLReducer),
    EffectsModule.forRoot([RTLEffects, LNDEffects, CLEffects]),
    !environment.production ? StoreDevtoolsModule.instrument() : []
  ],
  declarations: [
    AppComponent
  ],
  providers: [
    { provide: LoggerService, useClass: ConsoleLoggerService },
    { provide: OverlayContainer, useClass: ThemeOverlay },
    { provide: PERFECT_SCROLLBAR_CONFIG, useValue: DEFAULT_PERFECT_SCROLLBAR_CONFIG },
    { provide: HTTP_INTERCEPTORS, useClass: AuthInterceptor, multi: true },    
    AuthGuard, SessionService
  ],
  bootstrap: [AppComponent]
})
github rednez / angular-user-idle / src / app / app.module.ts View on Github external
import { ApiInfoComponent } from './api-info/api-info.component';

@NgModule({
  declarations: [
    AppComponent,
    TimerComponent,
    HeaderComponent,
    DescriptionComponent,
    FooterComponent,
    GithubIconComponent,
    ApiInfoComponent
  ],
  imports: [
    BrowserModule,
    FormsModule,
    UserIdleModule.forRoot({idle: 60, timeout: 120, ping: 60}),
    BrowserAnimationsModule,
    MatButtonModule,
    MatCardModule,
    MatInputModule,
    MatBadgeModule
  ],
  providers: [],
  bootstrap: [AppComponent]
})
export class AppModule {
}

angular-user-idle

User's idle service for Angular 13+

MIT
Latest version published 2 years ago

Package Health Score

53 / 100
Full package analysis

Popular angular-user-idle functions

Similar packages