In order to communicate between the panel and the plugin, the Plugin UI API and the SDK provide some utility methods.
Sending and receiving messages
To communicate from the panel to the plugin, we use the sendMessage method.
Then, in the Plugin we listen for the onMessage event.
To communicate from the plugin to the panel, the procedure is very similar. We use the sendMessage method from the SDK.
And then in the plugin panel we listen for the event, using the onMessage method: