Skip to content
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

feat: add JSDoc style comment support to Typescript generator #621

Merged
merged 14 commits into from
Mar 9, 2022
Merged

feat: add JSDoc style comment support to Typescript generator #621

merged 14 commits into from
Mar 9, 2022

Conversation

gabormagyar
Copy link
Contributor

Might need tests; tests for comment generation are already included just not for them being included. Don't think it needs docs as the feature is automatic and self explanatory.

Make sure to filter whitespace changes when viewing diff.

@gabormagyar gabormagyar changed the title feat: Add JSDoc style comment support to Typescript generator feat: add JSDoc style comment support to Typescript generator Feb 8, 2022
Copy link
Member

@jonaslagoni jonaslagoni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small specific comment, also remember to add tests to ensure it works as intended 👍

It seems you might have auto-formatting enabled in your development environment making unnecessary changes that make it harder to review, do you mind disabling it and re-commit the intended changes? 🙂

src/generators/typescript/TypeScriptRenderer.ts Outdated Show resolved Hide resolved
@gabormagyar
Copy link
Contributor Author

Auto formatting removed

@jonaslagoni
Copy link
Member

@gabormagyar sorry I did not caught this the first time, this has to be added as a preset instead, similar to what is being done here: #649 and what we have for Java https://github.com/asyncapi/modelina/blob/master/docs/languages/Java.md#include-javadoc-for-properties already.

We need to remember, that it's up to the users how the output model should sticked together 🙂

@coveralls
Copy link

coveralls commented Mar 3, 2022

Pull Request Test Coverage Report for Build 1955916041

  • 14 of 16 (87.5%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.03%) to 92.978%

Changes Missing Coverage Covered Lines Changed/Added Lines %
src/generators/typescript/presets/DescriptionPreset.ts 13 15 86.67%
Totals Coverage Status
Change from base Build 1944920494: 0.03%
Covered Lines: 2581
Relevant Lines: 2649

💛 - Coveralls

@gabormagyar
Copy link
Contributor Author

@jonaslagoni Please re-review

Copy link
Member

@jonaslagoni jonaslagoni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

We are only missing an example and updating the documentation: https://github.com/asyncapi/modelina/blob/master/docs/languages/JavaScript.md

Otherwise there are no easy way for others to know about it 🙂

@jonaslagoni jonaslagoni requested a review from Samridhi-98 March 7, 2022 09:15
@gabormagyar gabormagyar requested a review from jonaslagoni March 7, 2022 09:31
Copy link
Collaborator

@Samridhi-98 Samridhi-98 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gabormagyar Please add typscript-generate-comment here. 😊

Copy link
Member

@jonaslagoni jonaslagoni left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was quick ⏩!

This looks good to me 👍

@Samridhi-98 do you want to make a review as well?

@Samridhi-98
Copy link
Collaborator

That was quick ⏩!

This looks good to me 👍

@Samridhi-98 do you want to make a review as well?

I checked rest looks good to me 🙂

Samridhi-98
Samridhi-98 previously approved these changes Mar 7, 2022
Copy link
Collaborator

@Samridhi-98 Samridhi-98 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@jonaslagoni
Copy link
Member

Got some linting problems 🙂

@Samridhi-98
Copy link
Collaborator

/rtm

@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 9, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@Samridhi-98
Copy link
Collaborator

/rtm

@asyncapi-bot asyncapi-bot merged commit 983f3ed into asyncapi:master Mar 9, 2022
@gabormagyar gabormagyar deleted the ts-comments branch March 9, 2022 08:26
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 0.52.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

@Samridhi-98
Copy link
Collaborator

@all-contributors please add @gabormagyar for code, test, docs, example

@allcontributors
Copy link
Contributor

@Samridhi-98

I've put up a pull request to add @gabormagyar! 🎉

@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 1.0.0-next.23 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants