How to detect when user has selected a layer when plugin is running

In code.js:

Then use postMessage and get it in ui.html

Please see the developer documentation:

2 Likes