Skip to content

Laravel 11 project with Sanctum API and Breeze | Tailwind Frontend

Notifications You must be signed in to change notification settings

kevinThulnith/Laravel-project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

82a4683 Β· Mar 4, 2025

History

13 Commits
Jan 27, 2025
Dec 25, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 25, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Jan 25, 2025
Mar 4, 2025
Dec 20, 2024
Dec 20, 2024
Dec 27, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024
Dec 20, 2024

Repository files navigation

Laravel Logo

Build Status Total Downloads Latest Stable Version License

Laravel 11 Project with Sanctum (API) and Breeze (Frontend)

This repository contains a Laravel 11 application featuring a Sanctum-based API for authentication and product management, along with a Breeze-powered frontend (styled with Tailwind CSS). Below are the key features, setup instructions, and usage details.

For a step-by-step guide to building this project from scratch, refer to the INSTALL.md documentation.

πŸš€ Key Features

πŸ” Authentication

  • Login
  • Logout
  • Email Verification
  • Built-in API authentication using Sanctum (requires API tokens for accessing and manipulating product data).

πŸ“¦ Product Management

  • Add Product
  • Delete Product
  • Edit Product
  • View Product
  • Only the users who created a product can manipulate its data.

🎨 Frontend

  • Built using Laravel Breeze for a simple and elegant user interface.

  • Fully responsive across multiple devices.

πŸ› οΈ Prerequisites

Before you begin, ensure you have the following installed on your system:

  • PHP >= 8.2
  • Composer
  • Node.js and npm
  • MySQL or any other supported database | SQLite

βš™οΈ Installation

  1. Clone the repository:

    git clone https://github.com/KevinThulnith/Laravel-project.git
    cd Laravel-project
  2. Install PHP dependencies:

    composer install
  3. Install JavaScript dependencies:

    npm install && npm run dev
  4. Set up your environment file:

    cp .env.example .env

    Update the .env file with your database credentials and other necessary configuration.

  5. Generate the application key:

    php artisan key:generate
  6. Run database migrations:

    php artisan migrate
  7. Seed initial data (if any):

    php artisan db:seed
  8. Serve the application:

    php artisan serve

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

🌐 API Endpoints

πŸ” Authentication

  • Login: POST /api/login
  • Logout: POST /api/logout
  • Email Verification: POST /api/email/verify

πŸ“¦ Product Management

  • Add Product: POST /api/products
  • Delete Product: DELETE /api/products/{id}
  • Edit Product: PUT /api/products/{id}
  • View Products: GET /api/products

πŸ“ Notes:

  • All product manipulation endpoints require an API token.
  • Only the user who created a product can edit or delete it.

🎨 Frontend

The frontend is built using Laravel Breeze and Tailwind styling, providing:

  • Authentication pages (login, registration, password reset, email verification).
  • Basic product management UI integrated with the backend API.

πŸ§ͺ Testing

Run the test suite to ensure everything is working as expected:

php artisan test

πŸ“œ License

This project is open-source and available under the MIT license.


Feel free to contribute and enhance the project! For questions or suggestions, open an issue or submit a pull request.