antvis/G6

The issue has been closed
The event passed to graph.on callback has incorect typing (IG6GraphEvent) #2724
agriniex posted onGitHub
- I have searched the issues of this repository and believe that this is not a duplicate.
Reproduction link
Steps to reproduce
- Use Typescript
- Subscribe to keydown or node:mousedown event
- Click on a node or press a key
- evt.target.isCanvas function is specified as available from type definitions but it is not, since those events are either GraphEvent or KeyboardEvent, but not IG6GraphEvent
Environment | Info |
---|---|
g6 | 4.1.16 |
System | - |
Browser | Any |
<!-- generated by antv-issue-helper. DO NOT REMOVE -->