Sends a message to all of the app's active processes. The other processes can listen for these messages by registering a callback with the appProcess.registerOnMessage
method.
Usage
import { appProcess } from "@canva/platform";// Primitive valueappProcess.broadcastMessage(true);// Literal valueappProcess.broadcastMessage("Hello world");// Complex objectappProcess.broadcastMessage({type: "person",name: "David",age: 33,location: {city: "Sydney",country: "Australia",},});
tsx
Parameters
Required
The message to send to the app's active processes. This can be a primitive value (e.g., a boolean), a literal (e.g., a string), or a more complex value (e.g., a deeply nested object).
Returns
void