New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added better support for jsdoc tags #136
Conversation
…e spaces between curly braces for jsdoc types should not be used to split into parts, fixes tj#135
…mation but the individual properties like nullable, nonNullable, variable and optional should be used
👍 |
👍 |
@evindor I see you're still actively developing on the library. Could you take a look at this PR? I'd really like to remove the git URL of my fork from my package.json :-D |
@gionkunz yeah sure, this one is pretty large and i'm currently quite busy with my regular job but i'll have a look ASAP. |
Hope i'll review it today/tomorrow. |
Cool thanks man. No worries I understand. |
Hi @evindor did you had a chance to review this PR? If you need me to change anything please let me know. |
Hey @evindor please let me know if you need anything else. |
@gionkunz I'm sorry it took so long :( |
nonsense @evindor! I appreciate that this project remains active, and the time you're able to throw at it. |
@evindor thanks for your review! Much appreciated. Now Ill update my assemble-dox plugin and start going crazy with complex jsdoc type tags :-)) |
Hi there
Great library! This is perfect for use in static site generators where I currently also created a plugin (for assemble.io https://www.npmjs.org/package/assemble-dox )
I always hoped to use some more complex JSdoc annotations / types tag in dox, so I've created this pull request. Basically it changes the parsing a bit to make it more robust for complex types and white spaces. Then it uses a parser / lexer module to parse the JSDoc tag type strings. As a side effect there is now also support for nullable, non-nullable, vairable and optional on param, return, throws and type tags. Also there is a new typesDescription field on the tag objects that contains an HTML formatted type string.
I've updated the existing tests slightly (i think there was a wrong handling with the
?
sign which is for flagging nullable and not optional) and also added new tests. I've also update the documentation.This PR solves #135 and #82.
Hope I got the whole picture here and didn't miss anything.
Cheers
Gion