UNPKG

782 BTypeScriptView Raw
1import { Type } from '@angular/core';
2import { EnvironmentProviders } from '@ngrx/store';
3/**
4 * Runs the provided effects.
5 * Can be called at the root and feature levels.
6 *
7 * @usageNotes
8 *
9 * ### Providing effects at the root level
10 *
11 * ```ts
12 * bootstrapApplication(AppComponent, {
13 * providers: [provideEffects([RouterEffects])],
14 * });
15 * ```
16 *
17 * ### Providing effects at the feature level
18 *
19 * ```ts
20 * const booksRoutes: Route[] = [
21 * {
22 * path: '',
23 * providers: [provideEffects([BooksApiEffects])],
24 * children: [
25 * { path: '', component: BookListComponent },
26 * { path: ':id', component: BookDetailsComponent },
27 * ],
28 * },
29 * ];
30 * ```
31 */
32export declare function provideEffects(effects: Type<unknown>[]): EnvironmentProviders;