Download the PHP package semhoun/slim-skeleton-mvc without Composer
On this page you can find all versions of the php package semhoun/slim-skeleton-mvc. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package slim-skeleton-mvc
Slim 4 MVC Skeleton
A modern web application skeleton based on Slim 4, using the MVC architecture. This project is ideal for quickly starting the development of an API or a web application with a robust stack.
๐ Features
- Framework: Slim 4.15 (PSR-7, PSR-15, PSR-17)
- PHP Version: 8.4+ required
- Dependency Injection Container: PHP-DI 7.0 with autowiring
- ORM: Doctrine ORM 3.5 with DBAL 4.4
- Database: SQLite by default (supports MySQL, PostgreSQL via configuration)
- Template Engine: Twig 3.4
- API Support: RESTful API skeleton with JSON rendering
- Logging: Monolog 3.9 with multiple handlers
- Console: Symfony Console 6.4 with custom commands
- Code Quality: PHP Insights 2.13 & Rector 2.2
- Debugging: Tracy integrated via slim-tracy
- Sessions: Odan Session 6.4 with secure storage
- Migrations: Doctrine Migrations 3.9
- Environment: vlucas/phpdotenv 5.6 for configuration (supports
.envfiles, system environment variables, and mandatory variables usingenv_required(['VAR1', 'VAR2']) - Proxy Support: Built-in proxy detection middleware
๐ ๏ธ Requirements
- PHP 8.4 or higher
- Composer 2.0 or higher
- SQLite extension (or MySQL/PostgreSQL for production)
- Required PHP extensions: json, pdo, pdo_sqlite
๐ ๏ธ Installation
1. Create the project
Use Composer to install the project:
2. Configuration
-
Copy the
.env.examplefile to.env: -
By default, the application uses a SQLite database located in
var/database.sqlite. For production, configure your database and other settings in the.envfile or via environment variables. -
Initialize the database:
- (Optional) Generate Doctrine proxies:
3. Run the application
You can use the PHP built-in development server:
Or use the console command:
The application will be accessible at http://localhost:8080.
4. Available Console Commands
๐งช Development Tools
Run unit tests:
Check code quality with PHP Insights:
Apply automatic Rector fixes:
Fix code style issues:
Run pre-commit checks (code style + rector + dos2unix):
A compose.yml file is provided to facilitate deployment. Here is a configuration example:
To launch the environment with Docker:
๐ Notes
- Ensure that the
varfolder has write permissions (for cache, logs, database) - Default credentials: admin / admin (change in production!)
- The project includes an error rendering system (HTML/JSON) based on the
Acceptheader - API routes are prefixed with
/api(configurable inconfig/settings/_base_.php)
๐ Documentation
๐ License
This project is licensed under the MIT License. See the LICENSE file for more details.
๐ Changelog
See the CHANGELOG.md file for version history and upcoming changes.
All versions of slim-skeleton-mvc with dependencies
ext-sqlite3 Version *
ext-json Version *
slim/slim Version ^4.14
slim/psr7 Version ^1.7
doctrine/orm Version ^3
doctrine/dbal Version ^4
doctrine/migrations Version ^3
symfony/cache Version ^7
php-di/slim-bridge Version ^3.4
monolog/monolog Version ^3.6
symfony/console Version ^6.0
slim/twig-view Version ^3.4
akrabat/proxy-detection-middleware Version ^1.0