import { InjectionToken, type EnvironmentProviders, type Host, type InjectOptions, type Injector, type Optional, type Provider, type Self, type SkipSelf, type Type } from '@angular/core'; type CreateInjectionTokenDep = Type | (abstract new (...args: any[]) => TTokenType) | InjectionToken; type CreateInjectionTokenDeps any, TFactoryDeps extends Parameters = Parameters> = { [Index in keyof TFactoryDeps]: CreateInjectionTokenDep | [ ...modifiers: Array, token: CreateInjectionTokenDep ]; } & { length: TFactoryDeps['length']; }; export type CreateInjectionTokenOptions any, TFactoryDeps extends Parameters = Parameters> = (TFactoryDeps[0] extends undefined ? { deps?: never; } : { deps: CreateInjectionTokenDeps; }) & { isRoot?: boolean; isFunctionValue?: boolean; multi?: boolean; token?: InjectionToken>; extraProviders?: Provider | EnvironmentProviders; }; type InjectFn = { (): TFactoryReturn; (injectOptions: InjectOptions & { optional?: false; } & { injector?: Injector; }): TFactoryReturn; (injectOptions: InjectOptions & { injector?: Injector; }): TFactoryReturn | null; }; type ProvideFn ? Item : TFactoryReturn> = (TNoop extends true ? (value: TReturn | (() => TReturn)) => Provider : () => Provider) & (TReturn extends Function ? (value: TReturn | (() => TReturn), isFunctionValue: boolean) => Provider : (value: TReturn | (() => TReturn)) => Provider); export type CreateInjectionTokenReturn = [ InjectFn, ProvideFn, InjectionToken, () => Provider ]; /** * `createInjectionToken` accepts a factory function and returns a tuple of `injectFn`, `provideFn`, and the `InjectionToken` * that the factory function is for. * * @param {Function} factory - Factory Function that returns the value for the `InjectionToken` * @param {CreateInjectionTokenOptions} options - object to control how the `InjectionToken` behaves * @returns {CreateInjectionTokenReturn} * * @example * ```ts * const [injectCounter, provideCounter, COUNTER] = createInjectionToken(() => signal(0)); * * export class Counter { * counter = injectCounter(); // WritableSignal * } * ``` */ export declare function createInjectionToken any, TFactoryDeps extends Parameters = Parameters, TOptions extends CreateInjectionTokenOptions = CreateInjectionTokenOptions, TFactoryReturn = TOptions['multi'] extends true ? Array> : ReturnType>(factory: TFactory, options?: TOptions): CreateInjectionTokenReturn; export declare function createNoopInjectionToken void, []>, 'extraProviders'> & (TValue extends (...args: any[]) => any ? { isFunctionValue: true; } : { isFunctionValue?: never; }) & (TMulti extends true ? { multi: true; } : { multi?: never; })>(description: string, options?: TOptions): CreateInjectionTokenReturn; export {};