@ngxs/store 3.8.2-dev.master-25397f3 → 3.8.2-dev.master-397e451
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +6 -757
- package/internals/custom-rxjs-subjects.d.ts +42 -0
- package/internals/index.d.ts +9 -204
- package/internals/initial-state.d.ts +8 -0
- package/internals/internal-tokens.d.ts +3 -0
- package/internals/memoize.d.ts +9 -0
- package/internals/metadata.d.ts +25 -0
- package/internals/ngxs-app-bootstrapped-state.d.ts +8 -0
- package/internals/state-stream.d.ts +15 -0
- package/internals/state-token.d.ts +7 -0
- package/internals/symbols.d.ts +88 -0
- package/internals/testing/fresh-platform.d.ts +1 -0
- package/internals/testing/helpers/ngxs-test.component.d.ts +8 -0
- package/internals/testing/helpers/ngxs-test.module.d.ts +10 -0
- package/internals/testing/index.d.ts +4 -28
- package/internals/testing/ngxs.setup.d.ts +7 -0
- package/internals/testing/skip-console-logging.d.ts +1 -0
- package/internals/testing/symbol.d.ts +14 -0
- package/operators/append.d.ts +5 -0
- package/operators/compose.d.ts +2 -0
- package/operators/iif.d.ts +10 -0
- package/operators/index.d.ts +13 -101
- package/operators/insert-item.d.ts +6 -0
- package/operators/patch.d.ts +7 -0
- package/operators/remove-item.d.ts +6 -0
- package/operators/types.d.ts +56 -0
- package/operators/update-item.d.ts +9 -0
- package/operators/utils.d.ts +8 -0
- package/package.json +2 -2
- package/plugins/actions.d.ts +15 -0
- package/plugins/index.d.ts +3 -62
- package/plugins/symbols.d.ts +13 -0
- package/plugins/utils.d.ts +29 -0
- package/schematics/src/actions/actions.factory.d.ts +3 -0
- package/schematics/src/ng-add/add-declaration.d.ts +4 -0
- package/schematics/src/ng-add/ng-add.factory.d.ts +9 -0
- package/schematics/src/starter-kit/starter-kit.factory.d.ts +3 -0
- package/schematics/src/state/state.factory.d.ts +3 -0
- package/schematics/src/store/store.factory.d.ts +3 -0
- package/schematics/src/utils/common/lib.config.d.ts +10 -0
- package/schematics/src/utils/common/project-files.config.d.ts +3 -0
- package/schematics/src/utils/common/properties.d.ts +1 -0
- package/schematics/src/utils/config.d.ts +119 -0
- package/schematics/src/utils/generate-utils.d.ts +4 -0
- package/schematics/src/utils/interfaces/package.interface.d.ts +7 -0
- package/schematics/src/utils/ng-utils/ast-utils.d.ts +99 -0
- package/schematics/src/utils/ng-utils/ng-ast-utils.d.ts +5 -0
- package/schematics/src/utils/ng-utils/project.d.ts +2 -0
- package/schematics/src/utils/ng-utils/standalone/app_config.d.ts +16 -0
- package/schematics/src/utils/ng-utils/standalone/code_block.d.ts +46 -0
- package/schematics/src/utils/ng-utils/standalone/index.d.ts +1 -0
- package/schematics/src/utils/ng-utils/standalone/rules.d.ts +38 -0
- package/schematics/src/utils/ng-utils/standalone/util.d.ts +28 -0
- package/schematics/src/utils/normalize-options.d.ts +11 -0
- package/schematics/src/utils/project.d.ts +19 -0
- package/src/actions/symbols.d.ts +7 -0
- package/src/actions-stream.d.ts +37 -0
- package/src/configs/messages.config.d.ts +13 -0
- package/src/decorators/action.d.ts +30 -0
- package/src/decorators/select/select-factory.d.ts +16 -0
- package/src/decorators/select/select.d.ts +7 -0
- package/src/decorators/select/symbols.d.ts +9 -0
- package/src/decorators/selector/selector.d.ts +9 -0
- package/src/decorators/selector/symbols.d.ts +73 -0
- package/src/decorators/selector-options.d.ts +5 -0
- package/src/decorators/state.d.ts +5 -0
- package/src/dev-features/ngxs-development.module.d.ts +10 -0
- package/src/dev-features/ngxs-unhandled-actions-logger.d.ts +17 -0
- package/src/dev-features/symbols.d.ts +8 -0
- package/src/execution/dispatch-outside-zone-ngxs-execution-strategy.d.ts +14 -0
- package/src/execution/internal-ngxs-execution-strategy.d.ts +10 -0
- package/src/execution/noop-ngxs-execution-strategy.d.ts +8 -0
- package/src/execution/symbols.d.ts +16 -0
- package/src/internal/dispatcher.d.ts +36 -0
- package/src/internal/fallback-subscriber.d.ts +3 -0
- package/src/internal/internals.d.ts +105 -0
- package/src/internal/lifecycle-state-manager.d.ts +24 -0
- package/src/internal/state-context-factory.d.ts +18 -0
- package/src/internal/state-factory.d.ts +61 -0
- package/src/internal/state-operations.d.ts +21 -0
- package/src/internal/state-operators.d.ts +2 -0
- package/src/internal/unhandled-rxjs-error-callback.d.ts +2 -0
- package/src/ivy/ivy-enabled-in-dev-mode.d.ts +6 -0
- package/src/module.d.ts +13 -0
- package/src/modules/ngxs-feature.module.d.ts +10 -0
- package/src/modules/ngxs-root.module.d.ts +10 -0
- package/src/ngxs-unhandled-error-handler.d.ts +16 -0
- package/src/operators/leave-ngxs.d.ts +7 -0
- package/src/operators/of-action.d.ts +56 -0
- package/src/plugin-manager.d.ts +13 -0
- package/src/plugin_api.d.ts +1 -0
- package/src/private_api.d.ts +3 -0
- package/src/public_api.d.ts +23 -0
- package/src/selectors/create-model-selector.d.ts +10 -0
- package/src/selectors/create-pick-selector.d.ts +6 -0
- package/src/selectors/create-property-selectors.d.ts +5 -0
- package/src/selectors/create-selector.d.ts +19 -0
- package/src/selectors/index.d.ts +5 -0
- package/src/selectors/private_api.d.ts +7 -0
- package/src/selectors/selector-checks.util.d.ts +9 -0
- package/src/selectors/selector-metadata.d.ts +7 -0
- package/src/selectors/selector-models.d.ts +10 -0
- package/src/selectors/selector-types.util.d.ts +6 -0
- package/src/selectors/selector-utils.d.ts +9 -0
- package/src/standalone-features/feature-providers.d.ts +7 -0
- package/src/standalone-features/index.d.ts +4 -0
- package/src/standalone-features/initializers.d.ts +29 -0
- package/src/standalone-features/plugin.d.ts +17 -0
- package/src/standalone-features/preboot.d.ts +26 -0
- package/src/standalone-features/provide-states.d.ts +18 -0
- package/src/standalone-features/provide-store.d.ts +22 -0
- package/src/standalone-features/root-providers.d.ts +8 -0
- package/src/store.d.ts +60 -0
- package/src/symbols.d.ts +102 -0
- package/src/utils/compose.d.ts +23 -0
- package/src/utils/create-dispatch-map.d.ts +4 -0
- package/src/utils/create-select-map.d.ts +4 -0
- package/src/utils/dispatch.d.ts +2 -0
- package/src/utils/freeze.d.ts +5 -0
- package/src/utils/public_api.d.ts +4 -0
- package/src/utils/select.d.ts +16 -0
- package/src/utils/store-validators.d.ts +5 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export type StateFn = (...args: any[]) => any;
|
|
2
|
+
/**
|
|
3
|
+
* Composes a array of functions from left to right. Example:
|
|
4
|
+
*
|
|
5
|
+
* compose([fn, final])(state, action);
|
|
6
|
+
*
|
|
7
|
+
* then the funcs have a signature like:
|
|
8
|
+
*
|
|
9
|
+
* function fn (state, action, next) {
|
|
10
|
+
* console.log('here', state, action, next);
|
|
11
|
+
* return next(state, action);
|
|
12
|
+
* }
|
|
13
|
+
*
|
|
14
|
+
* function final (state, action) {
|
|
15
|
+
* console.log('here', state, action);
|
|
16
|
+
* return state;
|
|
17
|
+
* }
|
|
18
|
+
*
|
|
19
|
+
* the last function should not call `next`.
|
|
20
|
+
*
|
|
21
|
+
* @ignore
|
|
22
|
+
*/
|
|
23
|
+
export declare const compose: (funcs: StateFn[]) => (...args: any[]) => any;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { ActionDef } from '../actions/symbols';
|
|
3
|
+
export type ActionMap = Record<string, ActionDef<any>>;
|
|
4
|
+
export declare function createDispatchMap<T extends ActionMap>(actionMap: T): { readonly [K in keyof T]: (...args: ConstructorParameters<T[K]>) => Observable<void>; };
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { Signal } from '@angular/core';
|
|
2
|
+
import { TypedSelector, ɵSelectorReturnType } from '../selectors';
|
|
3
|
+
export type SelectorMap = Record<string, TypedSelector<unknown>>;
|
|
4
|
+
export declare function createSelectMap<T extends SelectorMap>(selectorMap: T): { readonly [K in keyof T]: Signal<ɵSelectorReturnType<T[K]>>; };
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { Signal } from '@angular/core';
|
|
2
|
+
import { TypedSelector } from '../selectors';
|
|
3
|
+
/**
|
|
4
|
+
* This function serves as a utility and has multiple purposes.
|
|
5
|
+
* Firstly, it allows you to select properties from the state class
|
|
6
|
+
* without having to inject the store class and use `this.store.selectSignal`,
|
|
7
|
+
* resulting in a more concise implementation. Secondly, it can be used with
|
|
8
|
+
* other solutions such as NgRx signal store with its `signalStoreFeature` or
|
|
9
|
+
* `withComputed` functionalities.
|
|
10
|
+
*
|
|
11
|
+
* Please note that it's named `select` instead of `selectSignal` because
|
|
12
|
+
* signals are evolving into first-class primitives in Angular, displacing other
|
|
13
|
+
* primitives such as observables. Observables represent a stream of events,
|
|
14
|
+
* whereas signals represent a single value changing over time.
|
|
15
|
+
*/
|
|
16
|
+
export declare function select<T>(selector: TypedSelector<T>): Signal<T>;
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ɵStateClassInternal } from '@ngxs/store/internals';
|
|
2
|
+
import { StatesByName } from '../internal/internals';
|
|
3
|
+
export declare function ensureStateNameIsValid(name: string | null): void | never;
|
|
4
|
+
export declare function ensureStateNameIsUnique(stateName: string, state: ɵStateClassInternal, statesByName: StatesByName): void | never;
|
|
5
|
+
export declare function ensureStatesAreDecorated(stateClasses: ɵStateClassInternal[]): void | never;
|