Page Contents

Home > @loopback/context > ResolutionOptions

ResolutionOptions interface

Options for binding/dependency resolution

Signature:

export interface ResolutionOptions 

Properties

Property Modifiers Type Description
[asProxyWithInterceptors?](/doc/en/lb4/apidocs.context.resolutionoptions.asproxywithinterceptors.html) boolean _(Optional)_ A boolean flag to control if a proxy should be created to apply interceptors for the resolved value. It's only honored for bindings backed by a class.
[optional?](/doc/en/lb4/apidocs.context.resolutionoptions.optional.html) boolean _(Optional)_ A boolean flag to indicate if the dependency is optional. If it's set to `true` and the binding is not bound in a context, the resolution will return `undefined` instead of throwing an error.
[session?](/doc/en/lb4/apidocs.context.resolutionoptions.session.html) [ResolutionSession](/doc/en/lb4/apidocs.context.resolutionsession.html) _(Optional)_ A session to track bindings and injections