Skip to content

Webview specific handlers are not cleaned up when webview is disposed #57

Description

@jonah-iden

When registering a message handler for a specific webview (sender = webviewId) then the handler is not disposed automaticly when the webview is disposed. The current webview onDidDispose code looks like this:

view.onDidDispose(() => {
    this.viewRegistry.delete(viewEntry.id);
    const removed = this.viewTypeRegistry.get(viewType)?.delete(view);
    if (!removed) {
        this.log(`Attempt to remove non-existing registry entry for View: ${viewEntry.id} (type ${viewType})`, 'warn');
    }
});

It would be nice if those webview specific handlers would be disposed here automaticly

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions