Token导航 LogoToken导航

Agent Skill · 研究检索

stitch-react-native-components(stitch React native 组件)

用于辅助前端页面、组件、样式和交互逻辑的开发与维护。它适合让 Agent 生成或审查 React、Next.js、Vue、Tailwind、CSS 等相关代码,整理组件结构,或定位布局和性能问题。使用时需要结合项目现有设计系统、路由和构建方式,避免只生成孤立片段;涉及页面改动时,应配合本地预览和构建检查确认视觉效果。

stitch-react-native-components 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为需要联网;许可证信息还不明确,第三方扫描有提醒项,按安装量在研究检索类的 73,675 个 Skill 里排第 53,170。

总安装 539周安装 22GitHub Stars 22下载 172核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:stitch-react-native-components(stitch React native 组件)
来源仓库:https://github.com/gabelul/stitch-kit
仓库路径:skills/stitch-react-native-components
安装命令:
npx skills add https://github.com/gabelul/stitch-kit --skill stitch-react-native-components
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/gabelul/stitch-kit --skill stitch-react-native-components

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

用于辅助 React Native 组件的开发与维护。适合生成或审查组件代码,整理结构并定位布局问题。需结合项目设计系统和构建方式,避免孤立片段。涉及页面改动时应配合本地预览确认视觉效果。stitch-react-native-components 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

安装前建议核验权限和维护状态,避免触发文件读写。

来源仓库内路径:skills/stitch-react-native-components

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/gabelul/stitch-kit --skill stitch-react-native…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要需要联网,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

stitch-react-native-components 怎么安装?

在终端执行 npx skills add https://github.com/gabelul/stitch-kit --skill stitch-react-native-component…。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

stitch-react-native-components 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

stitch-react-native-components 需要什么权限?

权限级别是需要联网。该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

stitch-react-native-components 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

stitch-react-native-components 用的人多吗?

公开数据是累计安装 539 次,近一周安装 22 次,下载 172 次,GitHub 22 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

stitch-react-native-components 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
stitch-react-native-components

stitch React native 组件 · 本页

53922需要联网未明确有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

Stitch → React Native / Expo Components

You are a React Native engineer. You convert Stitch mobile designs (deviceType: MOBILE) into cross-platform React Native components using Expo. You work in TypeScript, use StyleSheet.create for styles, and follow Expo Router conventions for navigation.

When to use this skill

Use this skill when:

  • The user wants a native mobile app (iOS + Android) from a Stitch design
  • The user mentions "React Native", "Expo", "mobile app", "iOS", "Android"
  • The Stitch design was generated with deviceType: MOBILE

Note: For a mobile WebView app (Capacitor, Ionic, PWA), use stitch-html-components instead. React Native outputs actual native UI — not web views.

Prerequisites

  • Stitch design generated with deviceType: MOBILE (desktop designs don't translate well to RN)
  • Target project uses Expo (SDK 50+) — not bare React Native
  • expo-router for file-based navigation

Step 1: Retrieve the design

Only call this skill for MOBILE Stitch designs. If the screenshot shows a desktop layout, stop and tell the user to regenerate with deviceType: MOBILE first.

  1. list_tools → find Stitch prefix
  2. [prefix]:get_screen → fetch design JSON
  3. Download HTML: bash scripts/fetch-stitch.sh "[htmlCode.downloadUrl]" "temp/source.html"
  4. Check screenshot.downloadUrl — verify it's a mobile layout (narrow, vertical)

Step 2: Project structure

app/
├── (tabs)/
│   ├── _layout.tsx       ← Tab navigator
│   ├── index.tsx         ← Home tab
│   └── [other-tabs].tsx
├── _layout.tsx           ← Root layout (ThemeProvider, SafeAreaProvider)
└── modal.tsx             ← Modal routes
src/
├── components/           ← Reusable components
│   └── [Name].tsx
├── data/
│   └── mockData.ts       ← Static content — never hardcoded in components
├── theme/
│   ├── tokens.ts         ← Design tokens as TypeScript constants
│   └── useTheme.ts       ← Hook to access current theme tokens
└── types/
    └── index.ts

Step 3: The HTML → React Native mapping

This is the core of the conversion. Apply these rules systematically:

Layout mapping

HTML/CSS→ React Native
<div style="display:flex; flex-direction:column"><View style={{flexDirection:'column'}}>
<div style="display:flex; flex-direction:row"><View style={{flexDirection:'row'}}>
<div style="display:grid; grid-template-columns:1fr 1fr"><View style={{flexDirection:'row', flexWrap:'wrap'}}> with width:'50%' children
overflow-y: scroll container<ScrollView>
Long lists<FlatList data={items} renderItem={...} keyExtractor={...}>
position: fixed bottom nav<View style={{position:'absolute', bottom:0, left:0, right:0}}>
position: absolute overlay<View style={{position:'absolute',...}}> inside a parent with position:'relative'

Content mapping

HTML→ React Native
<p>, <span>, text nodes<Text>
<h1> → <h6><Text> with large font size + fontWeight: 'bold'
<img src="..."><Image source={{uri: '...'}} style={{width:X, height:Y}}>
<button><Pressable> (preferred) or <TouchableOpacity>
<a> (navigation)<Pressable onPress={() => router.push('/route')}>
<input type="text"><TextInput>
<input type="password"><TextInput secureTextEntry={true}>
<input type="checkbox">Custom or @expo/vector-icons + Pressable
<select> / dropdown@react-native-picker/picker or custom modal picker
<nav> (tabs)Expo Router <Tabs> layout

Spacing mapping

React Native uses unitless numbers (dp — density-independent pixels):

// Approximate Tailwind → RN
const spacing = {
  1: 4,   // p-1 = 4dp
  2: 8,   // p-2 = 8dp
  3: 12,
  4: 16,
  5: 20,
  6: 24,
  8: 32,
  10: 40,
  12: 48,
  16: 64,
}

Color mapping

// src/theme/tokens.ts — extract from Stitch Tailwind config
export const lightTokens = {
  background: '#FFFFFF',   // from --color-background
  surface: '#F4F4F5',
  primary: '#6366F1',
  primaryFg: '#FFFFFF',
  text: '#09090B',
  textMuted: '#71717A',
  border: '#E4E4E7',
} as const

export const darkTokens = {
  background: '#09090B',
  surface: '#18181B',
  primary: '#818CF8',      // Lighter shade for dark bg
  primaryFg: '#09090B',
  text: '#FAFAFA',
  textMuted: '#A1A1AA',
  border: '#27272A',
} as const

export type ThemeTokens = typeof lightTokens

Step 4: Dark mode with useColorScheme

// src/theme/useTheme.ts
import { useColorScheme } from 'react-native'
import { lightTokens, darkTokens, type ThemeTokens } from './tokens'

/**
 * Returns the current theme's design tokens.
 * Automatically switches based on system color scheme.
 */
export function useTheme(): ThemeTokens {
  const scheme = useColorScheme()
  return scheme === 'dark' ? darkTokens : lightTokens
}
// Usage in any component
import { useTheme } from '@/theme/useTheme'

export function Card({ title }: { title: string }) {
  const theme = useTheme()

  return (
    <View style={[styles.card, { backgroundColor: theme.surface, borderColor: theme.border }]}>
      <Text style={[styles.title, { color: theme.text }]}>{title}</Text>
    </View>
  )
}

const styles = StyleSheet.create({
  card: {
    borderRadius: 12,
    borderWidth: 1,
    padding: 16,
    marginBottom: 12,
  },
  title: {
    fontSize: 16,
    fontWeight: '600',
  },
})

Step 5: Safe area and platform considerations

// app/_layout.tsx — root layout
import { SafeAreaProvider } from 'react-native-safe-area-context'
import { Stack } from 'expo-router'

export default function RootLayout() {
  return (
    <SafeAreaProvider>
      <Stack>
        <Stack.Screen name="(tabs)" options={{ headerShown: false }} />
      </Stack>
    </SafeAreaProvider>
  )
}
// In screen components — use safe area insets
import { useSafeAreaInsets } from 'react-native-safe-area-context'

export default function HomeScreen() {
  const insets = useSafeAreaInsets()

  return (
    <View style={{ flex: 1, paddingTop: insets.top, paddingBottom: insets.bottom }}>
      {/* Content */}
    </View>
  )
}

Step 6: Component template

// src/components/StitchComponent.tsx
import { View, Text, Pressable, StyleSheet } from 'react-native'
import { useTheme } from '@/theme/useTheme'

/**
 * Props for StitchComponent.
 * All data via props — never fetched inside the component.
 */
interface StitchComponentProps {
  title: string
  description?: string
  onPress?: () => void
}

/**
 * StitchComponent — [describe purpose in one sentence]
 */
export function StitchComponent({ title, description, onPress }: Readonly<StitchComponentProps>) {
  const theme = useTheme()

  return (
    <Pressable
      style={({ pressed }) => [
        styles.container,
        {
          backgroundColor: theme.surface,
          borderColor: theme.border,
          opacity: pressed ? 0.8 : 1,   // Visual feedback on press
        },
      ]}
      onPress={onPress}
      accessible={true}
      accessibilityRole="button"
      accessibilityLabel={title}
      hitSlop={8}   // Increase tap area without changing visual size
    >
      <Text style={[styles.title, { color: theme.text }]}>{title}</Text>
      {description ? (
        <Text style={[styles.description, { color: theme.textMuted }]}>{description}</Text>
      ) : null}
    </Pressable>
  )
}

const styles = StyleSheet.create({
  container: {
    borderRadius: 12,
    borderWidth: 1,
    padding: 16,
    gap: 8,
    // Minimum touch target
    minHeight: 44,
  },
  title: {
    fontSize: 16,
    fontWeight: '600',
    lineHeight: 24,
  },
  description: {
    fontSize: 14,
    lineHeight: 20,
  },
})

Step 7: Accessibility in React Native

// Every interactive element needs these props
<Pressable
  accessible={true}
  accessibilityRole="button"    // "button" | "link" | "text" | "image" | "header" | ...
  accessibilityLabel="Close dialog"   // What screen reader announces
  accessibilityHint="Double tap to close the modal"  // Optional extra context
  accessibilityState={{ disabled: false, selected: false }}
>

// Images
<Image
  accessible={true}
  accessibilityLabel="Profile photo of Emma Johnson"  // Descriptive alt text
  // OR for decorative:
  accessible={false}
/>

// Text hierarchy (screen reader uses accessibilityRole="header" for h1-h6 equivalent)
<Text accessibilityRole="header" style={styles.pageTitle}>Dashboard</Text>

Execution steps

  1. Verify it's a MOBILE Stitch design
  2. Data layer — create src/data/mockData.ts from the static content in the design
  3. Tokens — create src/theme/tokens.ts from extracted colors, and useTheme.ts
  4. Components — convert each visual section to a component using the mapping rules above
  5. Screen — compose components in the Expo Router screen file (app/(tabs)/index.tsx)
  6. Verify — run npx expo start and test on both iOS Simulator and Android Emulator

Troubleshooting

IssueFix
StyleSheet.create type errorImport StyleSheet from 'react-native'
Text outside <Text> errorEvery string must be inside <Text> — even {' '} spaces
Flex layout looks wrongRN defaults to flexDirection:'column' — explicit is safer
Image not showingRequires explicit width and height on the style
Keyboard pushes layout upUse KeyboardAvoidingView with behavior='padding' on iOS
Bottom safe area overlapUse useSafeAreaInsets() from react-native-safe-area-context

References

  • resources/component-template.tsx — Boilerplate RN component
  • resources/architecture-checklist.md — Pre-ship checklist
  • scripts/fetch-stitch.sh — Reliable GCS HTML downloader

平台分布

Codex

33.74%
按下载量换算58

Claude

31.96%
按下载量换算55

Cursor

19.17%
按下载量换算33

Gemini CLI

8.45%
按下载量换算15

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills