-1

I see this demo https://konvajs.github.io/docs/sandbox/Free_Drawing.html

I have been able to draw on successful web desktop, but can not draw on mobile

Please help me

1 Answers1

1

KonvaJs comes with mobile events to provide support for mobile devices. All you need to do is to listen to those events as well. I have changed the events to touchend, touchstart & touchmove. So now it will work on mobile. Here's the plunkr.

stage.on('contentTouchstart.proto', () =>{});
stage.on('contentTouchmove.proto', () =>{});
stage.on('contentTouchend.proto', () =>{});

Note: If you want to provide support for both you need to set listners for both.

Hope it helps.

Hitesh Kumar
  • 3,508
  • 7
  • 40
  • 71