Skip to content

LJFamily2/NextJS_ThemXua

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

77 Commits
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Thềm Xưa Restaurant Website

A modern, multilingual restaurant website built with Next.js for QuÑn Thềm Xưa, a Vietnamese seafood restaurant in TÒy Ninh, Vietnam. The website features comprehensive SEO optimization, multilingual support, and a responsive design.

Description

This is a professional restaurant website that showcases Thềm Xưa's seafood cuisine, dining areas, VIP rooms, and booking services. The website is designed to attract families, young adults, tourist groups, and corporate events with an emphasis on Vietnamese seafood dining experiences. The site features advanced SEO implementation targeting Vietnamese search engines and local business optimization.

Tech Stack

Frontend

  • Next.js 15.3.3 - React framework with App Router
  • React 19 - UI library
  • TypeScript - Type-safe JavaScript
  • Tailwind CSS - Utility-first CSS framework
  • Keen Slider - Touch slider library

Backend & Server

  • Express.js - Node.js web framework
  • Mongoose - MongoDB object modeling
  • Helmet - Security middleware
  • CORS - Cross-origin resource sharing
  • Express Rate Limit - API rate limiting

SEO & Analytics

  • Vercel Analytics - Web analytics
  • Vercel Speed Insights - Performance monitoring
  • Custom SEO Implementation - Structured data, sitemaps, robots.txt
  • Multi-language SEO - Vietnamese, English, Chinese, Khmer

Development Tools

  • ESLint - Code linting
  • Prettier - Code formatting
  • PostCSS - CSS processing
  • Autoprefixer - CSS vendor prefixes

Deployment

  • Vercel - Hosting and deployment platform
  • Custom Express Server - Production server configuration

Features

🌐 Multilingual Support

  • 4 languages: Vietnamese (default), English, Chinese, Khmer
  • Dynamic language switching
  • SEO-optimized language routing
  • Localized content management

🍽️ Restaurant Features

  • Hero Section - Eye-catching landing page
  • Menu Showcase - Interactive food gallery
  • Dining Areas - Outdoor, private rooms, banquet halls
  • VIP Rooms - Luxury dining spaces (5 different rooms)
  • Booking System - Table reservation functionality
  • Events & News - Latest updates and announcements

πŸ” Advanced SEO

  • Technical SEO - Optimized meta tags, structured data
  • Local Business Schema - Google Business integration
  • Multilingual Sitemaps - Dynamic XML sitemaps
  • Robots.txt Optimization - Search engine directives
  • Performance Optimization - Image optimization, lazy loading

πŸ“± Responsive Design

  • Mobile-first approach
  • Cross-device compatibility
  • Touch-friendly interactions
  • Optimized images for different screen sizes

πŸš€ Performance

  • Server-side rendering (SSR)
  • Static site generation (SSG)
  • Image optimization
  • Code splitting and lazy loading
  • Compression and caching

Prerequisites

Before running this project, make sure you have the following installed:

  • Node.js - Version 18.0 or higher
  • npm or yarn - Package manager
  • MongoDB - Database (local or cloud instance)
  • Git - Version control

Environment Variables

Create a .env.local file in the root directory with the following variables:

# Database
MONGODB_URI=your_mongodb_connection_string

# Server Configuration
NODE_ENV=production
PORT=3000

# SEO & Analytics
NEXT_PUBLIC_SITE_URL=https://yourwebsite.com
VERCEL_ANALYTICS_ID=your_vercel_analytics_id

# Contact Information
NEXT_PUBLIC_PHONE=+84971807272
NEXT_PUBLIC_EMAIL=themxuaintn@gmail.com

Installation & Setup

Follow these steps to set up the project locally:

1. Clone the Repository

git clone https://github.com/yourusername/NextJS_ThemXua.git
cd NextJS_ThemXua/themxua

2. Install Dependencies

npm install
# or
yarn install

3. Setup Environment Variables

# Copy the environment template
cp .env.example .env.local

# Edit the .env.local file with your actual values

4. Run the Development Server

npm run dev
# or
yarn dev

5. Build for Production

# Build the application
npm run build

# Start the production server
npm run start

The application will be available at http://localhost:3000.

Usage

Development Mode

  • Visit http://localhost:3000 to view the website
  • Use the language switcher in the header to test multilingual functionality
  • Navigate through different sections: Menu, VIP Rooms, Booking, Events

Production Deployment

  • The site uses a custom Express.js server for production
  • Deploy to Vercel or your preferred hosting platform
  • Configure environment variables in your hosting platform

Content Management

  • Update translations in app/translations/ directory
  • Modify SEO settings in app/lib/seo.ts
  • Add new images to public/images/
  • Update menu items and content in respective component files

Folder Structure

themxua/
β”œβ”€β”€ app/                          # Next.js App Router
β”‚   β”œβ”€β”€ [lang]/                   # Dynamic language routing
β”‚   β”œβ”€β”€ api/                      # API routes
β”‚   β”‚   β”œβ”€β”€ robots/              # Dynamic robots.txt
β”‚   β”‚   └── sitemap/             # Dynamic sitemap
β”‚   β”œβ”€β”€ booking/                  # Booking page
β”‚   β”œβ”€β”€ components/              # React components
β”‚   β”‚   β”œβ”€β”€ sections/            # Page sections
β”‚   β”‚   └── ui/                  # UI components
β”‚   β”œβ”€β”€ contexts/                # React contexts
β”‚   β”œβ”€β”€ events/                  # Events page
β”‚   β”œβ”€β”€ lib/                     # Utility libraries
β”‚   β”‚   β”œβ”€β”€ analytics.ts         # Analytics configuration
β”‚   β”‚   β”œβ”€β”€ seo.ts              # SEO configuration
β”‚   β”‚   └── structured-data.ts   # Schema markup
β”‚   β”œβ”€β”€ menu/                    # Menu page
β”‚   β”œβ”€β”€ news/                    # News page
β”‚   β”œβ”€β”€ party/                   # Party/Events page
β”‚   β”œβ”€β”€ translations/            # Language files
β”‚   β”‚   β”œβ”€β”€ en.json             # English translations
β”‚   β”‚   β”œβ”€β”€ vi.json             # Vietnamese translations
β”‚   β”‚   β”œβ”€β”€ zh.json             # Chinese translations
β”‚   β”‚   └── km.json             # Khmer translations
β”‚   β”œβ”€β”€ utils/                   # Utility functions
β”‚   β”œβ”€β”€ vip/                     # VIP rooms page
β”‚   β”œβ”€β”€ globals.css              # Global styles
β”‚   β”œβ”€β”€ layout.tsx               # Root layout
β”‚   └── page.tsx                 # Homepage
β”œβ”€β”€ lib/                         # Shared utilities
β”œβ”€β”€ public/                      # Static assets
β”‚   β”œβ”€β”€ images/                  # Image assets
β”‚   └── robots.txt              # Static robots.txt
β”œβ”€β”€ next.config.ts              # Next.js configuration
β”œβ”€β”€ tailwind.config.ts          # Tailwind CSS configuration
β”œβ”€β”€ package.json                # Dependencies and scripts
β”œβ”€β”€ server.js                   # Custom Express server
β”œβ”€β”€ tsconfig.json               # TypeScript configuration
└── SEO_GUIDE.md               # SEO implementation guide

Contributing

We welcome contributions to improve the website! Please follow these guidelines:

Getting Started

  1. Fork the repository
  2. Create a feature branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

Code Style

  • Follow the existing code style and conventions
  • Use TypeScript for type safety
  • Follow ESLint and Prettier configurations
  • Write meaningful commit messages

Areas for Contribution

  • Translation improvements
  • SEO enhancements
  • Performance optimizations
  • Accessibility improvements
  • New features and components
  • Bug fixes and testing

License

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

Contact

Project Information

  • Restaurant: QuΓ‘n Thềm XΖ°a TΓ’y Ninh
  • Address: 23 HoΓ ng LΓͺ Kha, Phường 3, TΓ’y Ninh, Vietnam
  • Phone: +84 971 807 272
  • Email: themxuaintn@gmail.com

Development Team

Website


Made with ❀️ for QuÑn Thềm Xưa TÒy Ninh

About

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors