Skip to content
This repository was archived by the owner on Sep 21, 2025. It is now read-only.
This repository was archived by the owner on Sep 21, 2025. It is now read-only.

Fill in random order: do not fill recurring keys randomly #47

@habenbam

Description

@habenbam

Scenario

I create the design for an item detail page of an e-commerce shop in Figma. Some information, such as the brand name of a product, is used in several places on the page. I have a JSON file with different products. I now want to fill the page with a random article from the JSON file. Suppose there is a key brandName in the JSON and all the layers in Figma that should display the brand name are named after this key.

Problem

When I select the option Populate in random order to populate the page with a random item, I have a different brand name for each layer named brandName. However, all occurrences of brandName should be given the same brand name, chosen at random. The problem then also occurs for all other keys. As a result, the information no longer fits together.

Possible solution

If the keys are selected randomly (Populate in random order), I can decide whether the randomly selected key from the JSON should apply to all matching layers in Figma. Maybe this is helpful for others as well? I'm not sure if the wording in the UI is appropriate.

👉 Please see my (forked) feature branch.

👇 An example where the key "name" is used twice. Using this json-test-file.

jsontofigma-merge.mov

Thank you for developing this plugin 🙏

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions