Page Contents

Home > @loopback/context > Context > getConfigSync

Context.getConfigSync() method

Resolve configuration synchronously for the binding by key


getConfigSync<ConfigValueType>(key: BindingAddress, configPath?: string, resolutionOptions?: ResolutionOptions): ConfigValueType | undefined;


Parameter Type Description
key BindingAddress Binding key
configPath string Property path for the option. For example, x.y requests for config.x.y. If not set, the config object will be returned.
resolutionOptions ResolutionOptions Options for the resolution.


ConfigValueType | undefined