How do I add interaction hooks with my plugin?

I’ve written a plugin that wraps react-tree. I can display a tree, open and close nodes in the tree, etc. When a user selects one of the nodes in the tree, not only does it open or close, it also becomes “selected”. There is an onSelect() hook in react-tree to allow you to do something. What i’d like to do is be able to use React Studio “User Interactions” to send the id of the selected node to another component (ReactTable), to force it to redraw its contents. But all of my “User Interactions” stuff is grayed out, making me think I need to define something else in my plugin to facilitate this. Anyone have any ideas?

Thanks.

Regards,
Dave

You probably need to to this so that the click saves the ID into Data slot which is then used as a ID value in the React table component.

There are currently at least two plugins available in Plugin Store that implement custom interactions: Camera and Firebase. See publishedInteractActions and writeReactWebCodeForPublishedInteractAction functions.