Home > typeioc > IContainer > tryResolveAsync
Asynchronously attempts to resolve a service with optional parameters.
Signature:
tryResolveAsync<R>(service: {}, ...args: {}[]): Promise<R | undefined>;
| Parameter | Type | Description | 
|---|---|---|
| service | {} | 
      service value registered prior resolution | 
| args | {}[] | 
      optional arguments for the service instantiation | 
Returns:
Promise<R | undefined>
null or undefined service value rejects the promise with ArgumentError