Dev figma script install

From Takazudo/claude-resources · View interactive version

Dev figma script install is an AI agent skill from the GitHub repository Takazudo/claude-resources. Guide installing the Figma capture script in a web project. Use for 'figma script install', 'add figma capture', 'figma setup'.

How to use this skill

Skill file

Figma Capture Script Installation

Guide for adding Figma's capture script to a web project so pages can be captured to Figma without Playwright injection.

Background

Figma MCP's generate_figma_design tool captures a rendered web page and converts it into editable Figma layers. The capture requires Figma's serializer script loaded on the page. Two approaches:

  1. Script in HTML (this skill) - embed the script for dev-only use. Simpler, faster.
  2. Playwright injection (via /dev-figma-capture) - inject at runtime. No source changes but heavier.

The Script

<script src="https://mcp.figma.com/mcp/html-to-design/capture.js" async></script>

What it does:

Installation Guidance

Add the script to the project's HTML only in development mode. Never ship to production.

Recommended Pattern (React/Vite)

{process.env.NODE_ENV === 'development' && (
  <script src="https://mcp.figma.com/mcp/html-to-design/capture.js" async />
)}

Important Notes

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.