Replies: 1 comment 1 reply
-
|
I can't get this to work fully though, the |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Just read this comment by @michaelfig in the
jsdoctypeparserrepo: jsdoctypeparser/jsdoctypeparser#50 (comment)It mentions the possibility of making assertion functions:
/** @returns {asserts foo is Bar} */I had no idea one could do this through JSDoc, I have so far always typed those functions using TypeScript definition files. Will surely try this out in future code, but wanted to share here right ahead so that I don't forget 👍
Beta Was this translation helpful? Give feedback.
All reactions