Skip to main content
Mikael_Ahlstrom
July 1, 2024

Create dividers with Plugin API – figma.createDivider()?

  • July 1, 2024
  • 15 replies
  • 412 views

I have built a simple plugin for my organization to generate our best practice Figma file boilerplate. I would love to be able to take advantage of the new page dividers feature, but if I use the API to edit the name of the page to something like ‘—’ it doesn’t turn into a divider like it would from the UI.

Feature requests

  1. Add ability to create dividers — Figma.createDivider()?
  2. Turn pages to divider if name is changed to “—” or similar like in UI

CleanShot 2024-07-01 at 11.18.45

15 replies

Mikael_Ahlstrom
July 15, 2024

@Andrey_Cretsu I don’t mean to sound rude, but if your code doesn’t still work, I suggest you google the error 😅 The problem is written in the end of that error message and solution is quite literally the first google result. Just add latest ECMAScript to your tsconfig.json and you’re good.

Shnitz
July 15, 2024

Same, naming the layer with ----- or **** just puts the names like this. I hope they will add this option to the plugin API

Gleb
Power Member
July 15, 2024

Everyone at Figma is very busy with AI now so it’s not guaranteed anyone would fix anything 😆😆

Jimmy.v
August 14, 2024

Same issue here.
It’s funny how everyone creates the same plugin in their organisations. 😅 (maybe an idea for another feature request haha).

tank666
November 22, 2024

Now you can create page dividers using API. Read more:

figma.com – 22 Nov 24
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