Function: isRefOfType()
function isRefOfType<T>(ref, refType): ref is Ref<T>;
Checks if a ref object is of a given ref type.
Type Parameters
| Type Parameter | Description |
|---|---|
T extends object | Referenced object type. |
Parameters
| Parameter | Type | Description |
|---|---|---|
ref | Ref<object> | Reference object. |
refType | RefConstructor<T> | Reference type. |
Returns
ref is Ref<T>
true if it is of the given type, false otherwise.