Skip to main content
Mikael_Ahlstrom
Jul 1, 2024 8:19 AM UTC

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

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
Jul 15, 2024 12:04 PM UTC

@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
Jul 15, 2024 12:38 PM UTC

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
Jul 15, 2024 1:11 PM UTC

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

Jimmy.v
Aug 14, 2024 2:59 PM UTC

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

tank666
Nov 22, 2024 8:58 PM UTC

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