Skip to content

Latest commit

Β 

History

110 Commits

Folders and files

NameName
Last commit message
Last commit date
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🍽️ Swift Food

Swift Food Banner

Swift Food License PRs Stars

Digital Menu for Cafes and Restaurants

Features β€’ Tech Stack β€’ Getting Started β€’ Project Structure β€’ Contributing

πŸ€” Why Swift Food?

  • 🌍 Open Source: Completely free and open-source. No hidden costs, no premium features.
  • πŸ”„ Actively Maintained: Everything is being updated and developed continuously.
  • ⚑ Fast & Simple: Built with cutting-edge technology for maximum performance.
  • 🎨 Modern Stack: Uses the latest web technologies for the best developer experience.

✨ Features

🎯 Core Features

  • πŸ“± Digital Menu Display: Beautiful, responsive menu for cafes and restaurants
  • πŸ‘₯ Multi-Vendor Support: Multiple restaurant owners can manage their menus
  • πŸͺ Restaurant Management: Complete CRUD for restaurant profiles
  • πŸ“‹ Category Management: Organize menu items with customizable categories
  • πŸ• Menu Item Management: Add, edit, and manage food items with images

πŸ”§ Technical Features

  • πŸ” JWT Authentication: Secure login for restaurant owners and admins
  • πŸ›‘οΈ Role-Based Access: Admin, Restaurant Owner, and Customer roles
  • πŸ“Έ Image Upload: Upload and manage images for menus and items
  • 🎨 Custom Branding: Each restaurant can have custom colors and themes
  • πŸ“± Mobile-First Design: iOS-style glassmorphism UI with responsive layout

πŸ› οΈ Refactor

  • Component
  • Filter
  • Edit modal
  • Routing
  • Type share
  • Auto redirect to dashboard
  • Seo
  • Performance

πŸš€ Coming Soon

  • Note order
  • Payment
  • RTL Support
  • Multi lang
  • Order management system
  • QR code generation for tables
  • Real-time order notifications
  • Analytics dashboard
  • Dark mode
  • PWA support
  • Dockerize
  • Admin Dashboard
  • Multi theme
  • Customer reviews and ratings

πŸ› οΈ Tech Stack

Frontend

React TypeScript Vite TailwindCSS Radix UI Framer Motion

Backend

Bun Hono MongoDB JWT

Tools

Turborepo Zod Zustand


πŸ“ Project Structure

Swift-Food/
β”œβ”€β”€ πŸ–₯️ client/ # Frontend React Application
β”‚ β”œβ”€β”€ src/
β”‚ β”‚ β”œβ”€β”€ components/ # Reusable UI components
β”‚ β”‚ β”‚ β”œβ”€β”€ layout/ # Header, Footer, Sidebar
β”‚ β”‚ β”‚ β”œβ”€β”€ menu/ # Menu items, categories
β”‚ β”‚ β”‚ β”œβ”€β”€ notebook/ # Cart/notebook functionality
β”‚ β”‚ β”‚ β”œβ”€β”€ owner/ # Restaurant owner panel
β”‚ β”‚ β”‚ └── ui/ # Base UI components (buttons, inputs)
β”‚ β”‚ β”œβ”€β”€ pages/ # Route pages
β”‚ β”‚ β”‚ β”œβ”€β”€ owner/ # Owner dashboard pages
β”‚ β”‚ β”‚ └── ... # Customer-facing pages
β”‚ β”‚ β”œβ”€β”€ services/ # API service layer
β”‚ β”‚ β”œβ”€β”€ store/ # Zustand state management
β”‚ β”‚ β”œβ”€β”€ types/ # TypeScript type definitions
β”‚ β”‚ └── lib/ # Utility functions
β”‚ β”œβ”€β”€ public/ # Static assets
β”‚ β”œβ”€β”€ vite.config.ts # Vite configuration
β”‚ └── package.json
β”‚
└── βš™οΈ server/ # Backend Hono Application
β”‚ β”œβ”€β”€ src/
β”‚ β”‚ β”œβ”€β”€ config/ # Database configuration
β”‚ β”‚ β”œβ”€β”€ controllers/ # Request handlers
β”‚ β”‚ β”œβ”€β”€ middleware/ # Auth, error handling, validation
β”‚ β”‚ β”œβ”€β”€ models/ # MongoDB schemas
β”‚ β”‚ β”œβ”€β”€ routes/ # API route definitions
β”‚ β”‚ β”œβ”€β”€ validators/ # Zod validation schemas
β”‚ β”‚ └── index.ts # Server entry point
β”‚ β”œβ”€β”€ uploads/ # Uploaded images
β”‚ └── package.json
β”‚
β”œβ”€β”€ πŸ“„ turbo.json # Turborepo configuration
β”œβ”€β”€ πŸ“„ package.json # Root package.json
└── πŸ“„ README.md # You are here!

πŸš€ Getting Started

Prerequisites

Before you begin, ensure you have the following installed:

Installation

  1. Clone the repository

    git clone https://github.com/mrrSwift/Swift-Food.git
    cd Swift-Food
    
    bun install
    
    cd server
    bun install
    
    cd client
    bun install
    
    # or use docker
    
    docker compose up -d
    

Set up environment variables

Create .env file in apps/server/:

MONGODB_URI=mongodb://localhost:27017/swift_food
JWT_SECRET=your-super-secret-jwt-key
JWT_EXPIRE=30d
PORT=3000
CORS_ORIGIN=http://localhost:5173
ZARINPAL_SANDBOX=true
FRONTEND_URL=http://localhost:5173
ZARINPAL_MERCHANT_ID=xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
STRIPE_SECRET_KEY=sk_test_...
STRIPE_PUBLIC_KEY=pk_test_...   # for frontend

Create .env file in apps/client/:

VITE_API_URL=http://localhost:3000
VITE_STRIPE_PUBLIC_KEY=pk_test_...
VITE_PAYMENT_METHOD=stripe 
VITE_LANG=fa

Run in Dev

# Run with turbo
bun dev 

# or run Separately
bun dev:client
bun dev:server

# or run standalone
# in two console run Separately
cd server
bun dev

cd client
bun dev

1- Areas We Need Help With

+ UI/UX Improvements
+ Bug fixes
+ Documentation
+ Test coverage
+ Performance optimization
- Currently not accepting major architectural changes

πŸ“ Development Notes

Current State

🟑 Alpha Stage: Core features working, but needs refinement

🟑 API: Stable but may have breaking changes

🟑 UI: Functional but needs polish

πŸ”΄ Testing: Not yet implemented

Known Issues

Image upload needs better error handling

Mobile responsiveness needs improvement in owner panel

No loading skeletons for data fetching

Missing form validation feedback

No offline support

πŸ“„ License

This project is licensed under the MIT License - see the LICENSE file for details.

🌟 Acknowledgments

Bun - Incredibly fast JavaScript runtime

Hono - Lightweight web framework

Vite - Next generation frontend tooling

Tailwind CSS - Utility-first CSS framework

Radix UI - Unstyled, accessible components

MongoDB - Flexible document database

πŸ“ž Contact & Support

Issues: GitHub Issues

Discussions: GitHub Discussions

Email: amirshayan1381@yahoo.com

⭐ Star us on GitHub β€” it motivates us a lot! ⬆ Back to Top

Made with ❀️ by MrrSwift

About

Digital menu for cafes and restaurants

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages