-
Notifications
You must be signed in to change notification settings - Fork 87
Open
Labels
Impact: LowenhancementNew feature or requestNew feature or requesttypescriptTypeScript definitions issueTypeScript definitions issuevaadin-context-menu
Description
As a developer when using TypeScript I want to be able to easily discover which event type I should use for an event handler when binding to @vaadin-contextmenu
. There should probably be a new event type for it and it should specify the type of the detail
object too.
See:
web-components/packages/vaadin-context-menu/src/vaadin-contextmenu-event.js
Lines 95 to 96 in b682812
const ev = new Event('vaadin-contextmenu', { bubbles: true, cancelable: true, composed: true }); ev.detail = { x, y, sourceEvent };
Would also be great if you could specify the type of event.currentTarget
via generics to make this kind of usage simpler (if possible) so that the user would not need to do so much casting (with as
):
Related: #1015
Metadata
Metadata
Assignees
Labels
Impact: LowenhancementNew feature or requestNew feature or requesttypescriptTypeScript definitions issueTypeScript definitions issuevaadin-context-menu