Monorepo Tamagui

Mindrally/skills/monorepo-tamagui

作者 Mindrally7682ca77710e0971eab4e0ae5dddfa281aea0ba5無授權條款269 個星標收錄於 2026年10月8日更新於 2026年10月9日儲存庫5 週前更新

Monorepo development guidelines using Tamagui, Turbo, Next.js, Expo, Supabase, and cross-platform best practices.

AI 產生的概覽

使用 Tamagui、Turbo、Next.js、Expo 與 Supabase 建置跨平台 monorepo 應用程式的開發指南。

功能
此技能為在 monorepo 中建置跨平台應用程式提供專家級開發指南。內容涵蓋程式碼風格、TypeScript 與 Zod 驗證、Tamagui 介面與樣式、Zustand 與 TanStack React Query 狀態管理、i18next 國際化、錯誤處理、效能最佳化、Turbo monorepo 結構、Solito 跨平台導覽,以及 Stripe 付款整合。它產出的是書面慣例與建議,而非程式碼或檔案。
適用情境
當你在結合 Next.js、Expo 與 Tamagui 的 TypeScript monorepo 中工作,並希望維持一致的慣例時使用。也適用於為這類專案加入跨平台導覽、共用狀態、國際化或 Stripe 訂閱功能。
執行需求
除代理外不需要任何指令碼或工具,它是一份純說明文件。所述技術堆疊涉及 TypeScript、React、Next.js、Expo、Tamagui、Supabase、Zod、Turbo、i18next、Zustand、TanStack React Query、Solito 與 Stripe,但閱讀這些指引無需安裝任何項目。

Monorepo using Tamagui

Expert developer guidelines for building cross-platform applications with TypeScript, React, Next.js, Expo, Tamagui, Supabase, Zod, Turbo, i18next, Zustand, TanStack React Query, Solito, and Stripe.

Code Style and Structure

  • Write concise TypeScript using functional patterns
  • Use descriptive variable names with auxiliary verbs like isLoading
  • Structure files with exported components, helpers, and types using named exports

TypeScript and Validation

  • Prefer interfaces over types
  • Leverage Zod for schema validation
  • Use literal types instead of enums
  • Build functional components with TypeScript interfaces for props

UI and Styling

  • Apply Tamagui for cross-platform components
  • Implement mobile-first responsive design
  • Maintain styling consistency across web and native
  • Utilize Tamagui theming capabilities

State Management

  • Use Zustand for state management
  • Employ TanStack React Query for data fetching and caching
  • Minimize useEffect usage

Internationalization

  • Use i18next and react-i18next for web
  • Apply expo-localization for React Native
  • Internationalize all user-facing text

Error Handling

  • Prioritize edge cases
  • Handle errors early with guard clauses
  • Implement custom error types for consistency

Performance Optimization

  • Optimize both web and native platforms
  • Use dynamic imports in Next.js
  • Implement lazy loading
  • Optimize images with proper formats

Monorepo Structure

  • Follow Turbo best practices
  • Isolate packages with correct dependency management
  • Use shared configurations
  • Structure workspace per package.json

Cross-Platform Development

  • Use Solito for navigation
  • Create .native.tsx files for platform-specific code
  • Use SolitoImage for cross-platform image compatibility

Stripe Integration

  • Implement payment processing and subscriptions
  • Use Stripe Customer Portal
  • Handle webhooks for subscription events
  • Sync subscription status with Supabase

來源與署名

來源:Mindrally/skills位於monorepo-tamagui提交7682ca7

授權條款: 無授權條款

內容歸原作者所有。SourceWeft 從公開儲存庫中收錄這些內容。

檢舉或申請下架