Skip to content

fix: removing TypeScript exported base model - #557

Merged
asyncapi-bot merged 4 commits into
asyncapi:masterfrom
jonaslagoni:feature/typescript_wrong_export
Jan 4, 2022
Merged

asyncapi-bot merged 4 commits into
asyncapi:masterfrom
jonaslagoni:feature/typescript_wrong_export

Conversation

@jonaslagoni

Copy link
Copy Markdown
Member

Description
The TypeScript renderers do more than provide the base data model, it also exports them and targets ESM module systems. This is a problem because the assumption is that the render renders a base data model that can be built upon after the rendering.

This PR removes that export functionality.

Related issue(s)
Related to #536

@coveralls

coveralls commented Jan 4, 2022 •

Copy link
Copy Markdown

Pull Request Test Coverage Report for Build 1654555782

  • 4 of 4 (100.0%) changed or added relevant lines in 4 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 93.232%

Totals Coverage Status
Change from base Build 1654179484: 0.0%
Covered Lines: 2315
Relevant Lines: 2364

💛 - Coveralls

magicmatatjahu
magicmatatjahu previously approved these changes Jan 4, 2022
magicmatatjahu
magicmatatjahu previously approved these changes Jan 4, 2022

@magicmatatjahu magicmatatjahu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM

@jonaslagoni

Copy link
Copy Markdown
Member Author

/rtm

@sonarqubecloud

sonarqubecloud Bot commented Jan 4, 2022

Copy link
Copy Markdown

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

@jonaslagoni

Copy link
Copy Markdown
Member Author

Hmm, funny...

So for the BlackBox tests when we render the type as:

interface Response {}

tsc see it as we are trying to overwrite the Response type located in the es5 lib.d.ts file 😅 Because we are not exporting the model 🤷

For now, I am gonna disable the tests, and re-enable them in #536

@jonaslagoni

Copy link
Copy Markdown
Member Author

/rtm

@asyncapi-bot
asyncapi-bot merged commit 17f8f7a into asyncapi:master Jan 4, 2022
@asyncapi-bot

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.40.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@jonaslagoni
jonaslagoni deleted the feature/typescript_wrong_export branch January 12, 2022 14:11
@asyncapi-bot

Copy link
Copy Markdown
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.

4 participants