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

@umituz/react-native-stitch-design

v0.1.1

Published

Google Stitch AI integration for React Native - Generate UI designs, convert to React Native components, and export design systems

Readme

@umituz/react-native-stitch-design

Google Stitch AI Integration for React Native 🎨

Generate high-fidelity UI designs using Google Stitch AI and convert them to production-ready React Native components.

npm version License: MIT

✨ Features

  • 🎨 AI-Powered UI Generation - Generate designs from natural language prompts
  • 🔄 Vibe Coding - Iteratively refine designs with conversational prompts
  • 🎭 3-Layer Vibe Structure - Anatomy + Vibe + Content framework
  • 📱 React Native Conversion - Auto-convert HTML/CSS to React Native components
  • 🎯 Design System Export - Extract themes, colors, typography
  • 🖼️ Sketch-to-UI - Convert hand-drawn sketches to coded interfaces
  • 🧩 MCP Integration - Compatible with coding agents
  • 🪄 Wizard Flows - Guided design generation workflows

🚀 Quick Start

Installation

npm install @umituz/react-native-stitch-design
# or
yarn add @umituz/react-native-stitch-design

Basic Usage

import React from 'react';
import { View } from 'react-native';
import { useStitchDesign, StitchDesignViewer } from '@umituz/react-native-stitch-design';

function App() {
  const { generateDesign, isLoading, error } = useStitchDesign();

  const handleGenerate = async () => {
    try {
      const design = await generateDesign({
        prompt: "A modern e-commerce home screen with Neo-Brutalism style",
        deviceType: "MOBILE"
      });
      console.log('Design generated!', design);
    } catch (err) {
      console.error('Failed to generate design', err);
    }
  };

  return (
    <View>
      <Button title="Generate Design" onPress={handleGenerate} />
      {design && <StitchDesignViewer design={design} />}
    </View>
  );
}

📖 Documentation

Hooks

useStitchDesign

Main hook for interacting with Google Stitch API.

const {
  generateDesign,
  refineDesign,
  getScreen,
  listProjects,
  createProject,
  isLoading,
  error
} = useStitchDesign({
  apiKey: process.env.STITCH_API_KEY
});

useStitchVibe

Work with the 3-Layer Vibe Structure.

const {
  generateVibePrompt,
  enhancePrompt,
  parsePrompt,
  suggestAnatomies,
  suggestVibes
} = useStitchVibe();

// Generate optimized prompt
const prompt = generateVibePrompt({
  anatomy: "Split-screen dashboard",
  vibe: "Glassmorphism, warm and inviting",
  content: "Real estate listings"
});

useDesignSystem

Extract design tokens from generated designs.

const { extractTheme, generateThemeFile, mergeThemes } = useDesignSystem();

const theme = await extractTheme({
  htmlCode: design.htmlCode,
  include: ['colors', 'typography', 'spacing']
});

useReactNativeConversion

Convert HTML/CSS to React Native components.

const { convertToReactNative } = useReactNativeConversion();

const result = await convertToReactNative(design.htmlCode, {
  framework: 'paper',
  includeStyles: true,
  extractComponents: true
});

Components

StitchDesignViewer

Preview generated designs in your app.

<StitchDesignViewer
  design={design}
  loading={isLoading}
  error={error}
  onError={(err) => console.error(err)}
/>

StitchPromptInput

Input component with vibe suggestions.

<StitchPromptInput
  onSubmit={(prompt) => generateDesign({ prompt, deviceType: 'MOBILE' })}
  placeholder="Describe your UI..."
  suggestions={true}
/>

Wizard Flow

Complete guided workflow for design generation.

import { StitchWizardFlow } from '@umituz/react-native-stitch-design/wizard';

<StitchWizardFlow
  onComplete={async (design) => {
    // Convert to React Native
    const rnCode = await convertToReactNative(design.htmlCode, {
      framework: 'paper'
    });

    // Export design system
    const theme = await extractTheme({ htmlCode: design.htmlCode });
  }}
  onCancel={() => console.log('Cancelled')}
/>

🎨 Supported Frameworks

  • React Native Paper - Material Design components
  • NativeWind - Tailwind CSS for React Native
  • NativeBase - Cross-platform UI kit
  • Tamagui - High-performance UI library

🧩 MCP Integration

This skill includes MCP server tools for coding agent integration:

  • stitch:generate_screen_from_text - Generate UI from prompt
  • stitch:get_screen - Get design details
  • stitch:list_projects - List all projects
  • stitch:refine_screen - Refine existing design

📦 App Initializer

For automatic setup:

// app-initializer.config.ts
export default {
  skills: [
    {
      name: '@umituz/react-native-stitch-design',
      options: {
        autoSetup: true,
        includeWizard: true,
        targetFramework: 'paper'
      }
    }
  ]
};

📝 License

MIT

🤝 Contributing

Contributions are welcome! Please open an issue or PR.

🔗 Links

👨‍💻 Author

Made with ❤️ by @umituz