-
-
Notifications
You must be signed in to change notification settings - Fork 6
Closed
Description
TypeScript offers the Readonly<T>
type function and the readonly
keyword. However, the isReadonlyOf
function seems a bit ambiguous. I propose the following improvements:
- Enhance
isReadonlyOf
for Array, Tuple, and Object types. - Introduce
isReadonlyFieldOf
for checking/annotating thereadonly
status of object fields. - Rename
isOptionalOf
toisOptionalFieldOf
to maintain consistency withisReadonlyFieldOf
. This change aligns with the handling of?
for object fields.
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request