Skip to main content
Bogriceanu_Sorin
New Participant
March 12, 2024
Solved

Shared pluginData between plugin and widget

  • March 12, 2024
  • 4 replies
  • 395 views

I am writing a Plugin that stores metadata on ComponentNodes as pluginData on the node. I have here an internal ID that matches the node to our internal Admin app database.

My goal is to write a Widget that would be able to read this pluginData. I know the process of reading it torugh plugin api, but the pluginData is segmented per pluginId.

In local dev I was thinking to use the same ID for the plugin and the widget. But would I be allowed to publish a plugin and a widget with the same ID?

Is there another pattern to share plugin data between them? (besides sharedPluginData)

Thanks,

Sorin

This topic has been closed for replies.
Best answer by tank666

And fileKey.

4 replies

tank666
March 12, 2024

This is impossible. Each published plugin and widget has unique IDs.

Send and store data on your server.

UX/UI designer. Figma expert. Creator and developer of plugins and widgets for Figma and FigJam. Check out my resources in Figma Community: figma.com/@tank
Bogriceanu_Sorin
New Participant
March 12, 2024

ah! and use node.id as join field, correct?

I was so deep into my way of doing it now… (I was storing the server id on pluginData)

tank666
tank666Answer
March 12, 2024

And fileKey.

UX/UI designer. Figma expert. Creator and developer of plugins and widgets for Figma and FigJam. Check out my resources in Figma Community: figma.com/@tank
Bogriceanu_Sorin
New Participant
March 12, 2024

good pint!

Thank you!