Replies: 1 comment
-
i dont know your specifications, but i would recommend to use |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Just wondering how to assign null to a field, so I find out the code in the typeguards.ts.
So master is
nullable
according to@prop({ ref: UserRef, default: null })
, but should we useNullable<Ref<UserRef>>
instead ofRef<UserRef>
?I know
public master?: Ref<UserRef>;
is equivalent topublic master: Ref<UserRef> | undefined;
but notnull
, so just wondering IfNullable<Ref<UserRef>>
orRef<UserRef> | null
is more type-correct?Beta Was this translation helpful? Give feedback.
All reactions