Skip to content

Conversation

@rohithyarramala
Copy link
Contributor

Title: fix: add auto-save functionality to AsyncAPI extension

Description:

Fixed the auto-save feature for AsyncAPI files to ensure they are automatically saved upon changes.

Updated onDidSaveTextDocument event to trigger visualizer and auto-save operations.

Updated Visualizer , visualizeAsyncApi method

Ensured proper event handling for AsyncAPI file visualization and updates upon save.

Fixed debug console logging to ensure proper output when running the extension.

Related issue(s):

Resolves #251

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Welcome to AsyncAPI. Thanks a lot for creating your first pull request. Please check out our contributors guide useful for opening a pull request.
Keep in mind there are also other channels you can use to interact with AsyncAPI community. For more details check out this issue.

@rohithyarramala rohithyarramala changed the title fix: add auto-save functionality to AsyncAPI extension fix: add auto-save (hot load) functionality to AsyncAPI extension Apr 18, 2025
@ibishal
Copy link
Contributor

ibishal commented Apr 23, 2025

can yu share a video recording, showing the hot reloaading is working

cc @rohithyarramala

@rohithyarramala
Copy link
Contributor Author

rohithyarramala commented Apr 23, 2025

@ibishal , please check it out

vs-code-hot-load-fix.2.1.mp4

Copy link
Contributor

@ibishal ibishal left a comment

Choose a reason for hiding this comment

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

LGTM

src/extension.ts Outdated
console.log('Reloading visualizer file', document.uri.fsPath);
visualizeAsyncApi(context);
if (isAsyncAPIFile(document)) {
console.log('File saved. Triggering visualizer reload for', document.uri.fsPath);
Copy link
Contributor

Choose a reason for hiding this comment

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

i dont think this is required

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@ibishal, ok i remove log !

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated please have a look and proceed

@sonarqubecloud
Copy link

Copy link
Collaborator

@ivangsa ivangsa left a comment

Choose a reason for hiding this comment

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

Thanks everyone for your hard work!
I'm approving this PR over #271 based on @ibishal's review, which suggests this one is the better option.
I'm pretty sure #271 is also outstanding, so once this version is released, could you help review and confirm everything is working as expected?

@ivangsa
Copy link
Collaborator

ivangsa commented Apr 25, 2025

/rtm

@ivangsa
Copy link
Collaborator

ivangsa commented Apr 25, 2025

/rtm

@asyncapi-bot asyncapi-bot merged commit 835a8b0 into asyncapi:master Apr 25, 2025
13 checks passed
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 0.8.1 🎉

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.

Make sure EDA Visualizer is hot reloaded

4 participants