You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<T>(ref: T): T extends Ref<infer V> ? V : T cannot exactly get inner Type of params which has a type K | Ref<K>
Type of unref should be <T>(ref: T | Ref<T>): T
When we use unref, we certainly want to get the inner Type of a ref or params' type. So it is better to use the genetic as inner Type of Ref or the type of a value which is not ref.
The text was updated successfully, but these errors were encountered:
Version
3.1.1
Reproduction link
https://codesandbox.io/s/awesome-bird-y636n?file=/src/demo.ts
Steps to reproduce
just click into the codesandbox link
What is expected?
the return type is
K
What is actually happening?
<T>(ref: T): T extends Ref<infer V> ? V : T
cannot exactly get inner Type of params which has a typeK | Ref<K>
Type of unref should be
<T>(ref: T | Ref<T>): T
When we use unref, we certainly want to get the inner Type of a ref or params' type. So it is better to use the genetic as inner Type of Ref or the type of a value which is not ref.
The text was updated successfully, but these errors were encountered: