-
-
Notifications
You must be signed in to change notification settings - Fork 185
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!: export and import interfaces as types when using named imports and ESM Module Syntax #1873
base: next
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for modelina canceled.
|
Quality Gate passedIssues Measures |
Pull Request Test Coverage Report for Build 8218001195Details
💛 - Coveralls |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Gonna have to re-target to next
because of the breaking changes to the dependency manager (it's exposed to users). Just need to make a quick update #1876 before I can do it.
Do you mind adding those changes to the migration docs: https://github.com/asyncapi/modelina/blob/next/docs/migrations/version-3-to-4.md
You should be able to easily merge next
into your branch 🙂
The merge-base changed after approval.
Are you sure this needs to go into the migration guide? This should not break anything afaik, environments that haven't used verbatim module Syntax before should still work with interfaces now exported/imported as types and environments that do will now work without causing errors. 🤔 I could certainly add this into the migration guide, it feels wrong there though as there is no action required. |
Its not the new feature that is breaking, but the syntax of the dependency manager functions, which are public interface for people to use 🙂 |
This pull request has been automatically marked as stale because it has not had recent activity 😴 It will be closed in 120 days if no further activity occurs. To unstale this pull request, add a comment with detailed explanation. There can be many reasons why some specific pull request has no activity. The most probable cause is lack of time, not lack of interest. AsyncAPI Initiative is a Linux Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model. Let us figure out together how to push this pull request forward. Connect with us through one of many communication channels we established here. Thank you for your patience ❤️ |
Description
When using modelType 'interface', exportType 'named' and moduleSystem 'ESM' export and import interfaces as types to support verbatimModuleSyntax.
This should not be a breaking change, interfaces are types even when not using verbatimModuleSyntax, explicitly marking them as types is optional in that case though.
Related Issue
fixes #1793
Checklist
npm run lint
).npm run test
).Additional Notes
This PR also includes a change that makes sure only interfaces are imported/exported as types, as the previous version of this PR also exported enums as types.