Star β this Repo to support its development!
ScannerFlow is a high-fidelity document scanning and digital archiving mobile app built with React Native & Expo. It provides a production-ready, cross-platform solution for iOS and Android, featuring advanced image processing, OCR, and a seamless user experience architected with Feature-Sliced Design.
This repository represents a modern, scalable, and maintainable approach to mobile application development, enforcing FAANG-level engineering standards.
- Architecture
- Key Features
- Getting Started
- Development Scripts
- Core Principles
- AI Agent Directives
- Contributing
- License
ScannerFlow strictly adheres to Feature-Sliced Design (FSD), a professional architectural methodology for frontend applications. This structure ensures high cohesion, low coupling, and clear separation of concerns, making the codebase scalable and easy to maintain.
sh src/ βββ app/ # 1. App-level logic (routing, providers, global styles) βββ processes/ # 2. Multi-screen business processes (e.g., user onboarding) βββ pages/ # 3. Full-screen components (e.g., HomePage, ScanPage) β βββ HomePage/ β βββ ScanPage/ βββ features/ # 4. Business logic features (e.g., DocumentScan, OcrProcessing) β βββ DocumentScan/ β βββ OcrProcessing/ βββ entities/ # 5. Core business entities (e.g., Document model and UI) β βββ Document/ βββ shared/ # 6. Reusable, non-business logic code (UI kit, libs, API) β βββ api/ β βββ config/ β βββ lib/ β βββ ui/ # Reusable UI components (Button, Card, etc.) βββ tsconfig.json
- Cross-Platform: Single codebase for both iOS and Android using React Native and Expo.
- High-Fidelity Scanning: Advanced image processing for clear, crisp document captures.
- OCR Integration: On-device or cloud-based Optical Character Recognition to extract text from documents.
- Digital Archiving: Organize, tag, and search scanned documents efficiently.
- Modern Stack: Built with TypeScript, ensuring type safety and developer productivity.
- Scalable Architecture: Feature-Sliced Design enables parallel development and simplified maintenance.
- High-Performance Tooling: Utilizes Biome for ultra-fast linting/formatting and Vitest for testing.
Follow these instructions to get the development environment running.
Prerequisites:
- Node.js (LTS version)
- Yarn or NPM
- Expo Go app on your mobile device or an emulator/simulator
Installation:
-
Clone the repository:
bash git clone https://github.com/chirag127/ScannerFlow-Document-Capture-And-Archive-Mobile-App.git cd ScannerFlow-Document-Capture-And-Archive-Mobile-App
-
Install dependencies:
bash npm install
-
Run the application:
bash npx expo start
Scan the QR code with the Expo Go app on your device, or press
afor Android Emulator orifor iOS Simulator.
| Script | Description |
|---|---|
npm start |
Starts the Metro bundler for development. |
npm run android |
Runs the app on a connected Android device/emulator. |
npm run ios |
Runs the app on the iOS simulator. |
npm run web |
Runs the app in a web browser. |
npm test |
Executes tests using Vitest. |
npm run lint |
Lints the codebase with Biome. |
npm run format |
Formats the codebase with Biome. |
- SOLID: Adherence to the five fundamental principles of object-oriented design.
- DRY (Don't Repeat Yourself): Reusable code is abstracted into the
sharedlayer. - YAGNI (You Ain't Gonna Need It): Features are implemented only when necessary to avoid bloat.
SYSTEM: APEX TECHNICAL AUTHORITY (DECEMBER 2025 EDITION)
Role: You are a Senior Principal Software Architect and Master Technical Copywriter with 40+ years of elite industry experience. You operate with absolute precision, enforcing FAANG-level standards. Context: Current Date is December 2025. You are building for the 2026 standard. Output Standard: Deliver EXECUTION-ONLY results. No plans, no "reporting"βonly executed code, updated docs, and applied fixes. Philosophy: "Zero-Defect, High-Velocity, Future-Proof."
This repository, ScannerFlow-Document-Capture-And-Archive-Mobile-App, is a TypeScript-based mobile application. Apply the corresponding Apex Toolchain.
-
PRIMARY SCENARIO: MOBILE APP (TypeScript / React Native)
- Stack: This project leverages React Native (with the Expo framework), TypeScript 6.x (Strict Mode), Zustand (for simple, scalable state management), and TanStack Query (for robust server-state management and data fetching).
- Architecture: Strictly adheres to Feature-Sliced Design (FSD), enforcing a clear hierarchy from
sharedlibraries up toapp-level composition. This modularizes features likeDocumentScanandOcrProcessingfor maximum scalability and maintainability. - Tooling: Biome is mandated for all linting and formatting, ensuring sub-second feedback loops and consistent code style. Vitest is the standard for unit and integration testing. E2E testing should utilize Maestro for its simplicity and reliability in the mobile context.
- UI/UX: The component library is built within
shared/ui, following atomic design principles. All components must be themeable, accessible, and performant.
-
VERIFICATION COMMANDS (MANDATORY):
- Run
npm run lintbefore every commit to ensure code quality. - Run
npm testto verify that all unit and integration tests are passing. - All new features must be developed within their designated FSD slice (
features/orentities/). - No business logic is permitted within the
pages/orapp/layers.
- Run
Contributions are welcome! Please read the CONTRIBUTING.md file for guidelines on how to submit pull requests.
This project is licensed under the Creative Commons Attribution-NonCommercial 4.0 International License - see the LICENSE file for details.
