drawHitFromCache
See original GitHub issueGreat work on the library so far. One gripe I have found is that there is no native implementation of drawHitFromCache
(or even cache
for that matter) on Image. You can work around it by storing a reference and setting the properties directly on the konva object but wouldn’t it be much nicer to have this inside react-konva ?
Issue Analytics
- State:
- Created 5 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Detecting image events for non-transparent pixels only ...
According to the doc, in order to have the event detection only for non-transparent pixels, I have to call methods cache() and drawHitFromCache...
Read more >HTML5 Canvas Image Events with Konva
To only detect events for non transparent pixels in an image with Konva, we can use the drawHitFromCache() method to generate a more...
Read more >JavaScript konva Image.drawHitFromCache Examples
drawHitFromCache - 2 examples found. These are the top rated real world JavaScript examples of konva.Image.drawHitFromCache extracted from open source ...
Read more >Detecting image events for non-transparent pixels only ...
Coding example for the question Detecting image events for non-transparent pixels only (drawHitFromCache) in Vue Konva-Vue.js.
Read more >konvajs/konva - Gitter
use drawHitFromCache,. konva.js:2771 Uncaught TypeError: Cannot read property 'scene' of undefined at Image.Node._getCachedSceneCanvas (konva.js:2771)
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
We need to think how to implement it. Probably we can do this:
react-konva
will try to automatically cache a node when possible.@heaversm yeh, you just need to call that method manually when a component is mounted.