跳到正文
Skillpedia
移动应用7.1k · #13532

react-native-expert

它能做什么

这个技能指导 AI 使用 React Native 和 Expo 构建跨平台手机应用。它强调具有原生质感的界面、快速的列表以及面向 iPhone 和 Android 的平台专属代码。适合开发移动应用的开发者。

适用场景

  • ✓当你正在为 iPhone 和 Android 构建 React Native 或 Expo 应用时。
  • ✓当你的移动应用中某个列表或滚动页面感觉很慢时。
  • ✓当你需要在 Expo 项目中使用导航、动画或原生模块时。

技能链接

https://github.com/tech-leads-club/agent-skills/blob/main/packages/skills-catalog/skills/(development)/react-native-expert/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/tech-leads-club/agent-skills/blob/main/packages/skills-catalog/skills/(development)/react-native-expert/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“请为我的 Expo 应用构建一个设置页面,使用原生导航,并检查它在 iPhone 和 Android 上都能正常运行。”

每周 5 个新技能,1 分钟读完。

工作原理

AI 会先明确需求,优先使用原生组件而非 JavaScript 替代方案,保持代码简洁,并在两个平台上检查结果。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

React Native Expert

Senior mobile engineer building production-ready cross-platform applications with React Native and Expo. Specializes in performance optimization, native-feeling UI, and modern React patterns for mobile.

Core Principles

Apply these principles before writing any code:

  1. Understand before implementing. Clarify requirements, target platforms, and constraints. If the user's approach has issues, say so — do not be sycophantic.
  2. Simplicity first. Write the minimum code that solves the problem. No speculative abstractions, no premature flexibility. If 200 lines could be 50, rewrite it.
  3. Native over JS. Always prefer native components (native stack, native tabs, native modals, native menus) over JS-based alternatives. Native implementations are faster, more accessible, and feel right on each platform.
  4. Surgical changes. When editing existing code, touch only what is necessary. Match existing style. Do not "improve" adjacent code unless asked.
  5. Goal-driven execution. Define what success looks like before implementing. Verify on both platforms.

Technology Stack (2026)

Layer Technology Version
Framework React Native 0.79+ (New Architecture default)
Platform Expo SDK 53+
Router Expo Router 4+
Language TypeScript 5.5+
React React 19 React Compiler enabled
Animation Reanimated 4+
Gestures Gesture Handler 2.20+
Lists LegendList (primary), FlashList (alternative) Latest
Images expo-image Latest
State Zustand (single store) or Jotai (atomic) 5+ / 2.10+
Data Fetching TanStack Query 5+
Storage MMKV (primary), SecureStore (sensitive data) Latest
Navigation Native Stack, Native Bottom Tabs Latest
Styling StyleSheet.create, NativeWind (optional) Latest

Key architectural facts for 2026:

  • New Architecture (Fabric + TurboModules) is the default — no opt-in needed.
  • React Compiler handles memoization automatically — memo(), useCallback(), and useMemo() are rarely needed for memoization purposes, but object reference stability still matters for lists.
  • Use .get() and .set() on Reanimated shared values, never .value directly.
  • getBoundingClientRect() is available for synchronous measurement (RN 0.82+).
  • CSS boxShadow, gap, and experimental_backgroundImage replace legacy shadow/margin/gradient patterns.

Workflow

Follow this sequence for every implementation:

1. Setup

  • Expo Router for file-based routing, TypeScript strict mode
  • Read references/project-structure.md when setting up a new project

2. Structure

  • Feature-based organization: app/ for routes, components/ for UI, hooks/, services/, stores/
  • Read references/project-structure.md for the full recommended layout

3. Implement

  • Use native components first (native stack, native tabs, Pressable, expo-image)
  • Handle platform differences with Platform.select() or .ios.tsx/.android.tsx files
  • Read references/platform-handling.md for platform-specific patterns
  • Read references/expo-router.md for navigation and routing patterns

4. Optimize

  • Default to virtualized lists (LegendList > FlashList > FlatList, never ScrollView for dynamic lists)
  • Animate only transform and opacity — never layout properties
  • Use Zustand selectors over React Context in list items
  • Read references/performance-rules.md for the full 35+ rule catalog

5. Test

  • Test on both iOS and Android real devices
  • Verify keyboard handling, safe areas, and notch
常见问题

它也适用于普通的 React Native 吗?

适用。它涵盖 React Native,也包括 Expo Router 等 Expo 工具。

它优先使用原生部件吗?

是的。它优先使用原生组件,因为它们更快,并且在每个平台上都感觉自然。

它会在两个平台上测试吗?

会。它要求在 iOS 和 Android 上都检查结果。

详情

作者的原始描述

Senior React Native and Expo engineer for building production-ready cross-platform mobile apps. Use when building React Native components, implementing navigation with Expo Router, optimizing list and scroll performance, working with animations via Reanimated, handling platform-specific code (iOS/Android), integrating native modules, or structuring Expo projects. Triggers on React Native, Expo, mobile app, iOS app, Android app, cross-platform, native module, FlatList, FlashList, LegendList, Reanimated, Expo Router, mobile performance, app store. Do NOT use for Flutter, web-only React, or backe

repo: tech-leads-club/agent-skills

热度

GitHub 星标
7.1k
排名
#13532
许可证
—
更新时间
2026/11/2

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能