UNPKG

@controladad/ng-base

Version:
40 lines (39 loc) 1.67 kB
import { Provider } from '@angular/core'; import { ApiInterceptor, TokenInterceptor, ErrorInterceptor } from './core'; import { CacGlobalConfig } from './configs'; export declare const provideApiBaseUrl: (urlFn: Function, deps?: any[]) => Provider; export declare const provideEnvironment: (urlFn: Function, deps?: any[]) => Provider; export declare const provideApiInterceptor: () => { provide: import("@angular/core").InjectionToken<readonly import("@angular/common/http").HttpInterceptor[]>; useClass: typeof ApiInterceptor; multi: boolean; }; export declare const provideErrorInterceptor: () => { provide: import("@angular/core").InjectionToken<readonly import("@angular/common/http").HttpInterceptor[]>; useClass: typeof ErrorInterceptor; multi: boolean; }; export declare const provideTokenInterceptor: () => { provide: import("@angular/core").InjectionToken<readonly import("@angular/common/http").HttpInterceptor[]>; useClass: typeof TokenInterceptor; multi: boolean; }; export interface CacBaseProviderConfig { initializeFn?: () => void; interceptorOnly?: boolean; providersOnly?: boolean; environment?: any; applicationName?: typeof CacGlobalConfig.applicationName; localization?: typeof CacGlobalConfig.localization; applyPrefixToStorageKeys?: typeof CacGlobalConfig.applyPrefixToStorageKeys; isProd?: boolean; apiBaseUrl?: string | { fn: Function; deps?: any[]; }; icons?: { names: string[]; directory: string; }; } export declare const provideCacBase: (configOrFn?: CacBaseProviderConfig | (() => CacBaseProviderConfig)) => Provider[];