JSDoc for keywords
Currently, we do not have JSDoc for built-in keywords (see image).
This seems to suggest adding JSDoc is not possible in the current api for keywords. Is that right, or is that something that can be done?
Asking because I'm curious to add JSDoc for my library (ArkEnv) that uses custom keywords.
Similar: https://discord.com/channels/957797212103016458/1335991632314499114

1 Reply
I don't think it would be possible to associate JSDoc with
"number"
in a context like that. It would be possible for type.number
, but obviously that's not the primary syntax.
What I mentioned had to do with preserving JSDoc for properties of a user-created object definition, which is possible as long as the key name is mapped 1:1 (e.g. by using .optional()
or string?
in the value for optionality without changing the key)