AI Decision System
Replayable, offline-verifiable records for AI-assisted go/no-go decisions: experiment promotions, typed model answers and human-approved actions.
Laravel 애플리케이션을 작고 재사용 가능한 모듈로 나누어 코드 구조와 유지보수를 향상시킵니다
Laravel Modules is a package designed to help organize Laravel applications into smaller, reusable, and modular components, enhancing code organization and maintainability.
개발 도구PHP · BladeGitHub @nWidart온라인운영자 미확인
써 보셨어요? 한 번만 눌러 주세요. 로그인은 필요 없어요.
Module Management In Laravel
저장소 README에서 가져옴
README 전체를 불러오는 중입니다.
README 전문 보기 ↗Modules/.module:make, module:make-controller, module:make-model, module:make-migration, and more.php artisan module:make Blog generates:
Modules/Blog/
├── app/ Http/Controllers, Providers
├── config/
├── database/ factories, migrations, seeders
├── resources/ assets, views
├── routes/ web.php, api.php
├── tests/ Feature, Unit
├── composer.json
├── module.json
├── package.json
└── vite.config.js
PHP 8.3+ and Laravel 13 for the current version. See Versions for older Laravel releases.
composer require nwidart/laravel-modules
The service provider and alias are registered automatically. To publish the config file (optional):
php artisan vendor:publish --provider="Nwidart\Modules\LaravelModulesServiceProvider"
Module classes are autoloaded through wikimedia/composer-merge-plugin. Add this to the extra section of your app's composer.json:
"extra": {
"laravel": {
"dont-discover": []
},
"merge-plugin": {
"include": [
"Modules/*/composer.json"
]
}
},
On first install, Composer asks:
Do you trust "wikimedia/composer-merge-plugin" to execute code and wish to enable it now? (writes "allow-plugins" to composer.json) [y,n,d,?]
Answer y. Or add it yourself:
"config": {
"allow-plugins": {
"wikimedia/composer-merge-plugin": true
}
}
If the plugin is set to false, modules are not autoloaded. After changing composer.json, run:
composer dump-autoload
Since v11.0, the
"Modules\\": "modules/"autoload entry is no longer needed. Remove it from yourcomposer.jsonif present.
php artisan module:make Blog # create a module
php artisan module:list # list modules and their status
php artisan module:disable Blog # stop booting the module
php artisan module:enable Blog # boot it again
| Laravel | laravel-modules |
|---|---|
| 13 | ^13.0 |
| 12 | ^12.0 |
| 11 | ^11.0 |
| 10 | ^10.0 |
Older Laravel versions use the matching major: 5.4 uses ^1.0, 5.5 uses ^2.0, through Laravel 9 with ^9.0.
Full documentation: https://laravelmodules.com/docs.
Originally based on pingpong/modules, which is no longer maintained.
MIT. See LICENSE.md.