toggleTouchMode

API reference for the "toggleTouchMode" method.

Enables or disables touch mode.

To call this method, select Enable touch interactions in the Developer Portal.

Usage

const canva = window.canva.init();
canva.onReady(async (opts) => {
// Enable touch mode
canva.toggleTouchMode(true);
// Disable touch mode
// canva.toggleTouchMode(false);
});

Parameters

Name

Type

Required

Description

visible

boolean

Yes

Set to true to enable touch mode. Set to false to disable touch mode.

Returns

void