Download the PHP package caiquebispo/laraslim without Composer
On this page you can find all versions of the php package caiquebispo/laraslim. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download caiquebispo/laraslim
More information about caiquebispo/laraslim
Files in caiquebispo/laraslim
Package laraslim
Short Description A lightweight PHP microframework combining Slim and Laravel features for fast and structured API development.
License MIT
Informations about the package laraslim
Description
LaraSlim is a microframework for PHP that combines the lightness of the Slim Framework with a structure inspired by Laravel. It's ideal for creating clean, modular APIs with a lightweight and fast setup.
Note: This project does not include an authentication engine by default. You can integrate your own or use third-party libraries.
It also doesn't include a template engine, but you can integrate it with Blade (Laravel) or any other engine of your choice.
⚠️ This is a beta project: some features may be under development and bugs may occur.
Features
- 🚀 Lightweight & Fast - Built on Slim Framework 4
- 🔒 Security First - CORS and Security Headers middlewares included
- 📝 Centralized Error Handling - PSR-3 logging, JSON error responses
- 🐳 Docker Ready - Multi-stage builds for dev and production
- ✅ Testing Infrastructure - Pest PHP with HTTP testing helpers
- 🔧 Environment Validation - Automatic validation of required variables
Requirements
- PHP ^8.4
- Docker (optional)
- Composer
Installation via Composer
Quick Start
Using PHP Built-in Server
Using Docker
Docker Commands
| Command | Description |
|---|---|
./bin/build |
Build Docker containers |
./bin/up |
Start Docker containers |
./bin/attach |
Attach to container |
./bin/down |
Stop Docker containers |
Application Access
- API:
http://localhost:8003(Docker) orhttp://localhost:8008(PHP server) - PHPMyAdmin:
http://localhost:8080(User:root, Password:root)
Project Structure
Environment Configuration
Copy .env.example to .env and configure:
Artisan Commands
Response Helpers
Exception Handling
Helper Functions
| Function | Description |
|---|---|
env($key, $default) |
Get environment variable |
config($key, $default) |
Get config value (dot notation) |
response() |
Get Response helper instance |
abort($code, $message) |
Throw HTTP exception |
logger() |
Get PSR-3 logger |
info($message) |
Log info message |
base_path($path) |
Get base path |
storage_path($path) |
Get storage path |
Security
LaraSlim includes built-in security middlewares:
- CORS - Configurable via
config/cors.phpor environment variables - Security Headers - X-Frame-Options, X-Content-Type-Options, HSTS (production)
Testing
Examples
Route Group
Controller with Response Helper
Author
- Caique Bispo
📧 [email protected]
License
This project is licensed under the terms of the MIT License.
All versions of laraslim with dependencies
slim/slim Version 4.*
slim/psr7 Version ^1.7
illuminate/database Version ^12.7
illuminate/http Version ^12.7
vlucas/phpdotenv Version ^5.6
php-di/php-di Version ^7.0
illuminate/validation Version ^12.7
symfony/console Version ^7.2
caiquebispo/blade-slim Version ^1.0