API reference
Design
addAudioTrackaddElementAtCursoraddElementAtPointaddNativeElementaddPagecreateRichtextRangeeditContentgetCurrentPageContextgetDefaultPageDimensionsgetDesignMetadatagetDesignTokeninitAppElementopenDesignoverlay.registerOnCanOpenrequestExportselection.registerOnChangesetCurrentPageBackgroundui.startDragToCursorui.startDragToPointui.startDrag
Intents: data
Intents: design
Platform
appProcessappProcess.broadcastMessageappProcess.currentappProcess.current.getInfoappProcess.current.requestCloseappProcess.current.setOnDisposeappProcess.requestCloseappProcess.registerOnMessageappProcess.registerOnStateChangefeatures.isSupportedfeatures.registerOnSupportChangegetPlatformInfonotification.addToastrequestOpenExternalUrl
features.registerOnSupportChange
API reference for the features.registerOnSupportChange method.
This version of the API is a preview. Preview APIs are unstable and may change without warning. You can't release public apps using this API until it's stable.
Registers a callback that runs when the context changes and an SDK method becomes supported or unsupported.
Usage: Monitoring feature support changes
import { features } from '@canva/platform';import { addElementAtPoint } from '@canva/design';const supportDisposer = features.registerOnSupportChange(() => {const isNowSupported = features.isSupported(addElementAtPoint);// Update UI based on new support status});// Later: cleanup the listenerawait supportDisposer();
TYPESCRIPT
Parameters
onSupportChange
function
Required
The callback that runs when the support status of an SDK method changes.
Returns
void
Returns
Disposes an event listener.
() => void