Event listener props should allow an object with `handleEvent` method
aleclarson opened this issue · comments
See this page from the docs.
If you're not using decorators, you can customize event listener options by passing an object to the event listener expression. The object must have a
handleEvent()
method and can include any the options that would normally appear in the options argument toaddEventListener()
.render() { return html`<button @click=${{handleEvent: () => this.onClick(), once: true}}>click</button>` }