resolveForwardRef
function
npm Package | @angular/core |
---|---|
Module | import { resolveForwardRef } from '@angular/core'; |
Source | core/src/di/forward_ref.ts |
function resolveForwardRef(type: any): any;
Description
Lazily retrieves the reference value from a forwardRef.
Acts as the identity function when given a non-forward-ref value.
Example (live demo)
const ref = forwardRef(() => 'refValue'); expect(resolveForwardRef(ref)).toEqual('refValue'); expect(resolveForwardRef('regularValue')).toEqual('regularValue');
See: forwardRef
© 2010–2017 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://v4.angular.io/api/core/resolveForwardRef