agentleFS
MindrallyMindrally/skills/monorepo/SKILL.md

monorepo

Skill275 starsChanged 36 days agoApache-2.0View on GitHub

Best practices for monorepo development with TypeScript, React, Next.js, Expo, Turbo, and related technologies

9 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use tauri, documentation and 2 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • klauswgSkill

    tauri

    Cross-platform app toolkit with Rust backend and WebView frontend. Use when building or maintaining Tauri apps, configuring IPC/security, or developing plugins.

    Also in 3 projects that use this

  • AnthropicSkill

    documentation

    Write and maintain technical documentation. Trigger with "write docs for", "document this", "create a README", "write a runbook", "onboarding guide", or when the user needs help with any form of technical writing — API docs, architecture docs, or operational runbooks.

    Also in 3 projects that use this

  • MicrosoftSkill

    diagnose

    Use to systematically diagnose why scenarios fail — identifies root causes by analyzing agent traces, codebase, and behavioral patterns

    Also in 3 projects that use this

  • GoogleSkill

    prototype

    Build a throwaway prototype to answer a design question. Use when the user wants to sanity-check whether a state model or logic feels right, or explore what a UI should look like.

    Also in 3 projects that use this

The file

Show its rules and text

We split this skill into the rules it gives an agent

26 rules. 0 are common, 21 are distinctive, and 5 are very specific to this project.

  • 0

    Common

    Most of the 5 edited versions we read keep these.

  • 21

    Distinctive

    This author's own choices. Worth a look.

  • 5

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Write concise, technical TypeScript code with accurate examples

    line 15
  2. Distinctive:

    Use functional and declarative programming patterns.

    line 16
  3. Distinctive:

    Prefer iteration and modularization over code duplication

    line 17
  4. Very specific:

    Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError)

    line 18
  5. Very specific:

    Use lowercase with dashes for directory names (e.g., components/auth-wizard)

    line 21
  6. Distinctive:

    Use TypeScript for all code.

    line 25
  7. Distinctive:

    Avoid enums; use literal types or maps instead

    line 27
  8. Distinctive:

    Use Zustand for state management

    line 32
  9. Distinctive:

    Use TanStack React Query for data fetching and caching

    line 33
  10. Distinctive:

    Follow best practices using Turbo for monorepo management

    line 39
  11. Very specific:

    Use separate apps and packages directories

    line 40
  12. Very specific:

    Keep shared configurations in the root configs/ directory

    line 41
  13. Distinctive:

    Use consistent naming conventions for workspaces

    line 42
  14. Distinctive:

    Follow the standard Turborepo workspaces directory structure:

    line 43
  15. Distinctive:

    Use i18next for web internationalization

    line 49
  16. Distinctive:

    Use expo-localization for React Native internationalization

    line 50
  17. Distinctive:

    Keep translation files organized by feature or domain

    line 51
  18. Distinctive:

    Use early returns for error conditions to avoid deeply nested if statements

    line 57
  19. Distinctive:

    Place the happy path last in the function for improved readability

    line 58
  20. Distinctive:

    Avoid unnecessary else statements.

    line 59
  21. Distinctive:

    Use guard clauses to handle preconditions and invalid states early

    line 60
  22. Distinctive:

    Use dynamic imports for code splitting

    line 65
  23. Distinctive:

    Use Solito for navigation across web and mobile

    line 72
  24. Very specific:

    Use .native.tsx files for platform-specific code

    line 73
  25. Distinctive:

    Use Supabase for authentication and database

    line 78
  26. Distinctive:

    Use Zod schemas for API validation

    line 80

“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Monorepo Development

You are an expert in TypeScript, React and Next.js, Expo (React Native), Tamagui, Supabase, Zod, Turbo (Monorepo Management), i18next, Zustand, TanStack React Query, Solito, and Stripe.

Code Style and Structure

  • Write concise, technical TypeScript code with accurate examples
  • Use functional and declarative programming patterns; avoid classes
  • Prefer iteration and modularization over code duplication
  • Use descriptive variable names with auxiliary verbs (e.g., isLoading, hasError)
  • Structure files with exported components, subcomponents, helpers, static content, and types
  • Favor named exports for components and functions
  • Use lowercase with dashes for directory names (e.g., components/auth-wizard)

TypeScript and Validation

  • Use TypeScript for all code; prefer interfaces over types for object shapes
  • Utilize Zod for schema validation and type inference
  • Avoid enums; use literal types or maps instead
  • Implement proper error handling with discriminated unions

State and Data Management

  • Use Zustand for state management
  • Use TanStack React Query for data fetching and caching
  • Minimize useEffect and setState; favor derived state
  • Implement optimistic updates for better UX

Monorepo Structure

  • Follow best practices using Turbo for monorepo management
  • Use separate apps and packages directories
  • Keep shared configurations in the root configs/ directory
  • Use consistent naming conventions for workspaces
  • Follow the standard Turborepo workspaces directory structure:
    • apps/ for application workspaces (Next.js, Expo apps)
    • packages/ for shared package workspaces (UI, utils, configs)

Internationalization

  • Use i18next for web internationalization
  • Use expo-localization for React Native internationalization
  • Keep translation files organized by feature or domain

Error Handling and Validation

  • Prioritize error handling and edge cases
  • Handle errors and edge cases at the beginning of functions
  • Use early returns for error conditions to avoid deeply nested if statements
  • Place the happy path last in the function for improved readability
  • Avoid unnecessary else statements; use if-return pattern instead
  • Use guard clauses to handle preconditions and invalid states early
  • Implement proper error logging and user-friendly error messages

Performance Optimization

  • Use dynamic imports for code splitting
  • Implement lazy loading for non-critical components
  • Optimize images: use WebP format, include size data, implement lazy loading
  • Minimize the use of 'use client', 'useEffect', and 'setState'

Cross-Platform Development

  • Use Solito for navigation across web and mobile
  • Use .native.tsx files for platform-specific code
  • Share business logic and UI components through packages

Backend Integration

  • Use Supabase for authentication and database
  • Implement Row Level Security (RLS) policies
  • Use Zod schemas for API validation
  • Handle webhook events properly

Payments

  • Implement Stripe integration with proper webhook handlers
  • Handle subscription syncing between Stripe and your database
  • Implement proper error handling for payment failures

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.