Skip to main content

@sabinmarcu/config

Index

Type Aliases

CheckParametersConsistencyOrError

CheckParametersConsistencyOrError<T>: ConsistentConfigParameters<T> extends false ? TypeError<Config input is not consistent> : T

Type parameters

ConfigListParameters

ConfigListParameters: Readonly<unknown[]>

ConfigListParametersCommonType

ConfigListParametersCommonType<T>: UnionToIntersection<TypeOfConfigParameters<T>>

Type parameters

ConfigMapParameter

ConfigMapParameter: Readonly<Record<string, any>>

ConfigObservablesFromParameters

ConfigObservablesFromParameters<Parameters>: { [ Key in keyof Parameters ]: Parameters[Key] extends Observable<any> ? Parameters[Key] : Observable<Parameters[Key]> }

Type parameters

ConfigParameters

ConfigResult

ConfigResult<T>: ConsistentConfigParameters<T> extends false ? TypeError<Config result cannot be derived from inconsistent input> : T extends ConfigListParameters ? ConfigListParametersCommonType<T> : MapConfigMapParameterToValues<T>

Type parameters

ConsistentConfigParameters

ConsistentConfigParameters<T>: T extends ConfigListParameters ? IsKnown<ConfigListParametersCommonType<T>> : true

Type parameters

MapConfigMapParameterKeyToObservable

MapConfigMapParameterKeyToObservable<T, Key>: T[Key] extends Observable<infer Value> ? Observable<{ [ key in Key ]: Value }> : Observable<{ [ key in Key ]: T[Key] }>

Type parameters

MapConfigMapParameterToObservables

MapConfigMapParameterToObservables<T>: { [ Key in keyof T ]: MapConfigMapParameterKeyToObservable<T, Key> }[keyof T][]

Type parameters

MapConfigMapParameterToValues

MapConfigMapParameterToValues<T>: { [ Key in keyof T ]: T[Key] extends Observable<infer Result> ? Result : T[Key] }

Type parameters

ObservableOf

ObservableOf<T>: T extends Observable<any> ? T : Observable<T>

Type parameters

  • T: any

TypeOfConfigParameters

TypeOfConfigParameters<T>: T extends ConfigListParameters ? TypeOfObservableOrType<T[number]> : never

Type parameters