A modern, high-performance Mobile Data Computer (MDC) system built with the Next.js App Router, TypeScript, and Tailwind CSS. This project is designed to handle complex data management—such as records, tickets, and searches—with a focus on speed, security, and a clean user interface.
- Framework: Next.js (App Router)
- Language: TypeScript (Strict Mode)
- Styling: Tailwind CSS
- Database: MySQL (via
src/lib/db.ts) - Icons/Assets: Custom vehicle and skin assets stored in
public/
The project follows a feature-based modular architecture to ensure scalability:
src/app/: Core routing, layouts, and API route handlers.src/features/: Modular business logic. Each feature (e.g.,search,office) contains its own:components/: Feature-specific UI.hooks/: Custom React hooks.api/: API client helpers.utils/: Constants and helper functions.
src/components/: Shared, reusable UI components.src/lib/: Shared infrastructure (Database connection logic, etc.).src/types/: App-wide TypeScript definitions and augmentations.
- Node.js (Latest LTS recommended)
- npm
- A MySQL instance
-
Clone the repository:
git clone https://github.com/mozyonee/mdc.git cd mdc -
Install dependencies:
npm install
-
Configure environment variables: Create a
.env.localfile in the root directory and add your database credentials:DB_HOST=your_host DB_PORT=3306 DB_USER=your_user DB_PASS=your_password DB_NAME=your_database NEXTAUTH_SECRET=secret NEXT_PUBLIC_GOOGLE_MAPS_API_KEY=api_key
Run the development server:
npm run devOpen http://localhost:3000 with your browser to see the result.
npm run dev: Starts the development server.npm run build: Creates an optimized production build.npm start: Serves the production build.npm run lint: Runs ESLint to check for code quality issues.
- Strict Typing: All features must adhere to strict TypeScript configurations.
- Environment Safety: Database credentials and secrets are managed via
.envfiles and are never committed to version control. - Modular Code: Prefer feature-scoped logic over bloated global utilities.
For detailed information on coding styles, naming conventions, and commit guidelines, please refer to AGENTS.md.
This project is licensed under the MIT License.