UNPKG

@loopback/docs

Version:

Documentation files rendered at [https://loopback.io](https://loopback.io)

28 lines (18 loc) 864 B
--- lang: en title: 'API docs: context.provider.value' keywords: LoopBack 4.0, LoopBack 4, Node.js, TypeScript, OpenAPI sidebar: lb4_sidebar editurl: https://github.com/loopbackio/loopback-next/tree/master/packages/context permalink: /doc/en/lb4/apidocs.context.provider.value.html --- <!-- Do not edit this file. It is automatically generated by API Documenter. --> [Home](./index.md) &gt; [@loopback/context](./context.md) &gt; [Provider](./context.provider.md) &gt; [value](./context.provider.value.md) ## Provider.value() method <b>Signature:</b> ```typescript value(): ValueOrPromise<T>; ``` <b>Returns:</b> [ValueOrPromise](./context.valueorpromise.md)<!-- -->&lt;T&gt; The value to inject to dependents. This method can return a promise too, in which case the IoC framework will resolve this promise to obtain the value to inject.