New: Improve the type of val()
This commit is contained in:
parent
6ac6aa87d7
commit
001c50c13d
1 changed files with 2 additions and 0 deletions
|
@ -227,6 +227,8 @@ export const val = <P>(
|
||||||
? T
|
? T
|
||||||
: P extends IDerivation<infer T>
|
: P extends IDerivation<infer T>
|
||||||
? T
|
? T
|
||||||
|
: P extends undefined | null
|
||||||
|
? P
|
||||||
: unknown => {
|
: unknown => {
|
||||||
if (isPointer(pointerOrDerivationOrPlainValue)) {
|
if (isPointer(pointerOrDerivationOrPlainValue)) {
|
||||||
return valueDerivation(
|
return valueDerivation(
|
||||||
|
|
Loading…
Reference in a new issue