Skip to main content
Question

Does instance layer hidden by variable mode increase memory usage?


Ethan_Wang

I have a layer in my main component that I’m hiding using variable mode. This component’s instance is used in many places. Given that the layer is hidden in all instances and only visible when I switch to the other mode, does it increase memory usage?

This topic has been closed for comments

3 replies

ksn
Figmate
  • Community Support
  • 1624 replies
  • January 12, 2024

@Ethan_Wang‌ I believe this will still increase memory usage – the layer is still present in all those instances, even if hidden, so they are still taking up memory in the background.


Ethan_Wang
  • Author
  • 2 replies
  • January 13, 2024

Thanks for the reply. Memory usage wise, is it the same as using the boolean property to toggle visibility? (I see it is recommended as the memory saving solution for hidden layers, so was wondering if using variable mode is just as effective)


ksn
Figmate
  • Community Support
  • 1624 replies
  • January 17, 2024

It depends on the design specifically, so it’s hard to say.

Typically, using boolean props + hidden layers = more or less layers than setting up each of those states. After consulting some other support team members on this, it sounds like boolean props help reduce layer count, but depending on the design, will not be the case.

Since this one is outside my current knowledge, I’d recommend asking the support team directly (and sharing a copy of the file you’re trying to reduce memory load on if you can): https://help.figma.com/hc/en-us/requests/new?ticket_form_id=360005944714. They can give you some specific advice on how to handle the memory load more efficiently.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings