phantom-php/framework

A minimalist but powerful PHP framework

Maintainers

Package info

github.com/Phantom-Framework-PHP/framework

Type:project

pkg:composer/phantom-php/framework

Statistics

Installs: 5

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

v1.19.6 2026-02-10 22:52 UTC

This package is auto-updated.

Last update: 2026-04-10 23:14:01 UTC


README

Phantom is a minimalist, elegant, and fast PHP framework, designed for developers seeking Laravel's structure with the lightness of a micro-framework.

๐Ÿš€ Quick Installation

You can create a new Phantom project instantly using Composer:

composer create-project phantom-php/framework my-app

Or manually:

  1. Clone the repository.
  2. Run composer install.
  3. Copy .env.example to .env and configure your credentials.
  4. Start your server: php phantom serve.

๐Ÿ“– Comprehensive Documentation

Our Documentation Manual covers everything you need to master Phantom:

Main Features

  • ๐Ÿ“ฆ IoC Container: Professional and powerful dependency management.
  • ๐Ÿ›ฃ๏ธ Advanced Routing: Route Groups, Named Routes, Middlewares, and Method Injection.
  • ๐ŸŽจ View Engine: Blade-like template system with layouts, components, and caching.
  • ๐Ÿ—„๏ธ Phantom ORM: Active Record with Eager Loading, Relationships, Polymorphism, Soft Deletes, Attribute Casting, and Mass Assignment Protection.
  • ๐Ÿข Multi-Tenancy Core (v1.19.3): Native support for database and scope isolation (shared or separate DBs).
  • โฑ๏ธ Rate Limiting Pro (v1.19.4): Distributed sliding window algorithm for precise request throttling.
  • โšก Distributed Cache (v1.19.5): High-performance caching with Redis Cluster support and automatic tenant isolation.
  • ๐Ÿค– AI Native Integration: Built-in support for Gemini/OpenAI, Vector Embeddings, and AI-powered validation.
  • ๐Ÿ“Ÿ Phantom Live: Build reactive, dynamic interfaces with PHP and Blade (Livewire-style).
  • ๐Ÿ“Š Phantom Pulse: Real-time telemetry dashboard for requests, DB queries, and security.
  • ๐Ÿ›ก๏ธ Native Security: Zero-config Security Shield (IP Reputation), CSRF protection, and secure hashing.
  • ๐Ÿ“ File Storage: Abstracted storage with Local, FTP, and S3 drivers.
  • ๐Ÿ“ฆ Distributed Queues: Background job processing with Redis Cluster and Sentinel support.
  • ๐Ÿ“ API Auto-Doc: Generate OpenAPI/Swagger documentation automatically using AI.
  • ๐Ÿงช Testing Suite: Built-in system for HTTP Feature Testing and unit tests.
  • ๐Ÿ’ป Phantom CLI: Professional toolkit including serve, migrate, tinker, and ai:generate.

Requirements

  • PHP 8.1 or superior.
  • Extensions: PDO, OpenSSL, Mbstring, Fileinfo, Readline (recommended).

Phantom CLI Quick Guide

# Start Server
php phantom serve

# Interactive REPL
php phantom tinker

# Run Migrations
php phantom migrate

# Generate Code
php phantom make:model Post
php phantom make:resource UserResource

License

This project is under the MIT License.

Designed with โค๏ธ for speed and elegance.