Skip to content

Mobile Stack

The Vulcan mobile app is built with React Native and Expo, providing a native experience on iOS and Android.

Core Technologies

TechnologyPurpose
React NativeCross-platform mobile application framework for building native iOS and Android apps
ExpoDevelopment platform and managed workflow for React Native with extensive APIs
Expo RouterFile-based routing system for navigation with deep linking support

UI Components

TechnologyPurpose
React Native PaperMaterial Design component library for React Native with theming support

API Integration

TechnologyPurpose
OpenAPI GeneratorAuto-generates type-safe API client from OpenAPI/Swagger specification
GraphQL Code GeneratorGenerates TypeScript types and TanStack Query hooks from GraphQL schema
graphql-requestLightweight GraphQL client for making API requests

Configuration & Monitoring

TechnologyPurpose
expo-constantsEnvironment variable management and app configuration
DatadogApplication performance monitoring, error tracking, and logging

Testing

TechnologyPurpose
JestJavaScript testing framework for unit and integration tests
React Native Testing LibraryComponent testing utilities focused on user behavior

Code Quality

TechnologyPurpose
ESLintJavaScript/TypeScript linting and code quality enforcement
PrettierOpinionated code formatter for consistent code style
commitlintEnforce Conventional Commits format for commit messages
SonarQubeStatic code analysis for code quality and security

Mobile-First Design Principles

Purpose-Built, Not Reduced

The mobile app is a purpose-built tool for field workers, not a reduced version of the desktop app:

  • Full functionality available offline
  • Voice input as primary alternative to typing
  • Large touch targets for use with gloves
  • GPS and camera integration

Offline-First Architecture

┌─────────────────────────────────────────────────┐
│                    Mobile App                    │
│  ┌───────────────────────────────────────────┐  │
│  │              TanStack Query                │  │
│  │  ┌─────────────┐   ┌──────────────────┐   │  │
│  │  │   Cache     │ ← │  Persistence     │   │  │
│  │  │  (memory)   │ → │  (AsyncStorage)  │   │  │
│  │  └─────────────┘   └──────────────────┘   │  │
│  └───────────────────────────────────────────┘  │
│                        ↕                         │
│  ┌───────────────────────────────────────────┐  │
│  │              Mutation Queue                │  │
│  │   [pending mutations when offline]         │  │
│  └───────────────────────────────────────────┘  │
└─────────────────────────────────────────────────┘

                 [When Online]

┌─────────────────────────────────────────────────┐
│                   Backend APIs                   │
└─────────────────────────────────────────────────┘

Tab Navigation (Main)

(tabs)/
├── index.tsx      → Dashboard
├── projects.tsx   → Projects list
├── leads.tsx      → CRM/Leads
└── profile.tsx    → User profile

Stack Navigation (Drill-down)

quote/
├── [id].tsx       → Quote details
└── create.tsx     → New quote wizard

project/
└── [id].tsx       → Project details

Build Commands

bash
# Development
npx expo start           # Start dev server
npx expo run:ios         # Run on iOS simulator
npx expo run:android     # Run on Android emulator

# Testing
npm run test             # Run Jest tests
npm run lint             # Run ESLint
npm run type-check       # TypeScript check

# Building
eas build --profile development --platform ios
eas build --profile preview --platform all
eas build --profile production --platform all

# Submitting
eas submit --platform ios
eas submit --platform android

Key Conventions

Important

  • Use React Native Paper for all UI components
  • Expo Router uses file-based routing - don't mix with React Navigation directly
  • Test on both iOS and Android - behavior can differ
  • Be careful with native modules - prefer Expo SDK when possible
  • EAS Build is required for native code - can't use Expo Go for everything

Built with VitePress | v1.1.0