- 
          
 - 
                Notifications
    
You must be signed in to change notification settings  - Fork 218
 
Open
Description
I have a js class that extends EventTarget to take advantage of js's built in event handling, but when I view an instance of that item in the component inspector it just says EventTarget and I'm unable to expand it or interact with it in anyway. Is there a way to get this to retain that functionality while extending that class?
class Dialog extends EventTarget {
    // ...
}
class DialogService {
    /**
     * Internal reference to the existing dialogs
     */
    public readonly instanceMap: Map<string, Dialog>;
    constructor() {
        this.instanceMap = reactive(new Map());
    }
    add(dialog: Dialog) {
        this.instanceMap.set(dialog.id, dialog);
        dialog.addEventListener('transitioned', () => this.remove(dialog);
    }
    // ...
}Metadata
Metadata
Assignees
Labels
No labels