npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

figma-plugin-by-vibe-coding

v1.0.1

Published

Figma Plugin by Vibe Coding - Plugin development boilerplate with AI tools, React, TypeScript, and shadcn/ui

Downloads

3

Readme

🚀 Figma Plugin by Vibe Coding

TypeScript Figma plugin boilerplate with AI development tools integration

npm version npm downloads TypeScript React Vite shadcn/ui License: MIT

A modern Figma plugin development setup with TypeScript, React, and AI development tools support.

✨ Features

🏗️ Tech Stack

  • TypeScript 5.6+ - Type safety with explicit annotations
  • React 18 - Functional components with hooks
  • Vite - Fast build system with HMR
  • shadcn/ui - Accessible component library
  • Tailwind CSS - Utility-first CSS framework
  • Biome - Linting and formatting

🤖 AI Development Integration

  • 15+ AI Tools Supported - Cursor, Claude, Copilot, Cline, and more
  • rulesync - AI development rules generation
  • Type-Safe Code Generation - Structured codebase for AI tools
  • AI Collaboration - Pre-configured patterns for AI assistance

🛡️ Development Features

  • HMR Stability - Solved CSS issues during hot reload
  • Error Handling - Result pattern implementation
  • Quality Tools - Automated lint + format + typecheck
  • Dual Process Architecture - Figma Plugin API compliance

🚀 Quick Start

1. Create New Plugin Project

# Create a new plugin using npm create command
npm create figma-plugin-by-vibe-coding my-awesome-plugin

# Or with AI tool selection
npm create figma-plugin-by-vibe-coding my-plugin cursor
npm create figma-plugin-by-vibe-coding my-plugin claudecode

# Navigate to your project
cd my-awesome-plugin

2. Generate AI Development Rules 🤖

If you're using AI-assisted development, generate the rule files for your preferred AI tool.

Configure AI Tool

Edit rulesync.jsonc to select your AI tool:

{
  // ✏️ Specify your preferred AI tool
  "targets": ["cursor"],  // or ["claudecode"], ["copilot"], etc.
}

Generate Rules

# Generate rules for configured AI tools
npm run rules:generate

⚠️ Note: You might see Node.js compatibility errors from rulesync, but files are generated successfully. Check for .cursor/, CLAUDE.md etc. to confirm success.

This generates files for your selected AI tool:

  • Cursor: .cursor/rules/ + custom commands
  • Claude Code: .claude/memories/ + specialized agents
  • GitHub Copilot: .github/instructions/ integration
  • Cline: .clinerules/ auto-generation
  • Others: Amazon Q, Qwen, Gemini, etc.

3. Start Development

# Start development server
npm run dev

# Or develop UI only in browser
npm run dev:ui-only  # http://localhost:3000

4. Load Plugin in Figma

  1. Open Figma Desktop
  2. Go to PluginsDevelopmentImport plugin from manifest...
  3. Select dist/manifest.json
  4. Your plugin is now loaded with demo random shape generation

📋 Development Commands

🔧 Basic Commands

npm run dev              # Start development server
npm run build            # Production build (hot reload safe)
npm run build:clean      # Clean build (for releases)
npm run dev:ui-only      # UI-only development in browser

🧹 Code Quality

npm run lint:fix         # Auto-fix linting issues
npm run format           # Format code
npm run typecheck        # TypeScript type checking

🤖 AI Development Tools

npm run rules:generate   # Generate AI tool rules

🏗️ Project Structure

src/
├── plugin/           # Plugin thread (Figma API)
│   └── main.ts       
├── ui/               # UI thread (React)
│   ├── components/   # UI components
│   ├── hooks/        
│   │   ├── core/     # Core functionality (communication, connection)
│   │   └── features/ # Feature-specific (custom logic)
│   └── styles/       # Global styles
├── common/           # Shared files
│   ├── messages.ts   # Communication contracts
│   ├── types.ts      # Type definitions
│   └── constants.ts  # Constants
└── .rulesync/        # AI development rules (auto-generated)

🎯 Demo Features

Random Shape Generation

  • Function: Generates random shapes (rectangles, ellipses, polygons)
  • Features: Random colors, sizes, and viewport positioning
  • Notifications: Native notifications via figma.notify()
  • Type Safety: TypeScript type checking

🤖 AI Development Tips

  1. AI Tool Setup: Configure your preferred AI tool in rulesync.jsonc
  2. Rule Updates: Run npm run rules:generate before implementing new features
  3. Expert Agents: Use Claude's figma-expert agent for specialized help
  4. Keep It Simple: Use rulesync's standard features as-is

💡 Troubleshooting

Build Errors During Hot Reload

# ❌ Issue: npm run build crashes the plugin
# ✅ Solution: Use hot reload safe build
npm run build        # Safe build (recommended)
npm run build:clean  # Full clean build (for releases only)

CSS Application Issues

  • CSS disappearing during HMR has been resolved
  • Protection mechanisms for stable style application
  • forceCSSSafety() for automatic recovery

rulesync Errors

# Node.js compatibility errors are expected but work correctly
ls .cursor CLAUDE.md  # Verify file generation

📦 npm create Command

# Basic usage
npm create figma-plugin-by-vibe-coding my-plugin

# With AI tool selection
npm create figma-plugin-by-vibe-coding my-plugin cursor
npm create figma-plugin-by-vibe-coding my-plugin claudecode

📝 License

MIT License - see LICENSE for details

🙋‍♂️ Support

  • Issues: GitHub Issues
  • Discussions: Project Discussions
  • Documentation: README-LLM.md (Detailed guide for LLM)

🌟 Contributing

Pull requests are welcome! See CONTRIBUTING.md for details.


Made with ❤️ for AI-assisted Figma plugin development