query-params-store
Version:
[](https://travis-ci.org/IliaIdakiev/query-param-store)
38 lines (37 loc) • 1.8 kB
TypeScript
import { OnDestroy } from '@angular/core';
import { Router, ActivatedRouteSnapshot, RouterStateSnapshot } from '@angular/router';
import { Observable } from 'rxjs';
import { IAllowedValuesConfig, IQueryParamsStoreModuleConfig } from './interfaces-and-types';
import * as i0 from "@angular/core";
declare type SelectorFn<T> = (a: any) => T;
export declare class QueryParamsStore<T = any> implements OnDestroy {
router: Router;
private snapshot;
private subscription;
private url;
private fullUrl;
private prevFullUrl;
private redirectUrl;
private isInDebugMode;
private useCompression;
private compressionKey;
store: Observable<T>;
private getConvertBinaryBooleanResult;
private getConvertValueResult;
private getTypeConverter;
private parseStateConfig;
private isBinaryBoolean;
private getSnapshotData;
private constructStore;
constructor(router: Router, config: IQueryParamsStoreModuleConfig);
_constructHandler(): void;
select<R = any>(selector: string | SelectorFn<R>, disableDistinctUntilChanged?: boolean, compare?: (x: any, y: any) => boolean): Observable<R>;
first<R>(selector?: string | SelectorFn<R>, predicate?: null, defaultValue?: R): Observable<R>;
private _match;
canActivate(allowedValues: IAllowedValuesConfig | Observable<IAllowedValuesConfig>, currentSnapshot: ActivatedRouteSnapshot): Observable<boolean>;
canDeactivate(allowedValues: IAllowedValuesConfig | Observable<IAllowedValuesConfig>, currentSnapshot: ActivatedRouteSnapshot, routerSnapshot: RouterStateSnapshot): Observable<boolean>;
ngOnDestroy(): void;
static ɵfac: i0.ɵɵFactoryDeclaration<QueryParamsStore<any>, never>;
static ɵprov: i0.ɵɵInjectableDeclaration<QueryParamsStore<any>>;
}
export {};