Skip to main content
Solved

isMask property problem

  • February 3, 2021
  • 2 replies
  • 591 views

Kama_Wojcik

Hey, I need to tell if a layer is a mask or not. I was trying isMask property, but it always returns false. Could anyone help?

Best answer by Kama_Wojcik

I just made it work too. There was a node inside my project which was called “mask” but technically wasn’t a mask. Sorry for bothering you, I guess the topic can be deleted.

View original
This topic has been closed for comments

2 replies

Gleb
  • Power Member
  • 4706 replies
  • February 3, 2021

It works fine for me, I just tried. I can set it and get it correctly. Can you show an example where it’s not working for you?

figma.currentPage.selection[0].isMask returns true when the selected layer is a mask.


Kama_Wojcik
  • Author
  • 1 reply
  • Answer
  • February 3, 2021

I just made it work too. There was a node inside my project which was called “mask” but technically wasn’t a mask. Sorry for bothering you, I guess the topic can be deleted.


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