Skip to main content
100%

16:9 - Figma

✓ Published0🌍 Public
KKevinGutowski
Last edited Oct 13, 2021
Created on Oct 13, 2021

This example demonstrates a Figma plugin that resizes a selected design element to fit a 16:9 aspect ratio. It calculates a multiplier based on the current width, then uses the `resize` method to set the dimensions to 16 times that multiplier and 9 times it, while also enabling `constrainProportions` to maintain the correct ratio. The code reads the selected frame's properties directly from the Figma API and modifies its dimensions accordingly.

AI-generated description

Similar vizzes