Skip to main content
Iuri_Fazli
Feb 2, 2023 2:37 PM UTC
Question

How i can get access to global object figma in ui.tsx?

I need access to figma global object in ui.tsx file. How i can get it? In code.ts it’s work, but in ui.tsx no 😦

This topic has been closed for replies.

1 reply

tank666
Feb 2, 2023 3:08 PM UTC

It’s impossible. If you want to access the global object from the UI, then you need to send a message from the UI to the plugin code, and then in the plugin code access the figma global object.

Please see the developer documentation for an example: Creating a User Interface | Plugin API

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