LaravelPackages.net
Acme Inc.
Toggle sidebar
rits/modular

Modular structure for laravel projects.

14
0
1.0.0
About rits/modular

rits/modular is a Laravel package for modular structure for laravel projects.. It currently has 0 GitHub stars and 14 downloads on Packagist (latest version 1.0.0). Install it with composer require rits/modular. Discover more Laravel packages by rits or browse all Laravel packages to compare alternatives.

Last updated

Modular

Build Status Coverage Status Code Climate Total Downloads Latest Stable Version Latest Unstable Version License

Offers a easy way to modularize your laravel app.

Installation

Require this package with composer:

composer require rits/modular

After updating composer, add the ModularServiceProvider to the providers array in config/app.php. Use vendor:publish command to create the configuration file.

php artisan vendor:publish --tag=rits/modular

Usage

You can choose wherever you want to store your modules. In most cases app/Modules is a good choice. Create a class that extends the ModuleDefinition class, and add the class name in the modular.php config file.

Example:

  • Create the app/Modules/Frontend/Module.php file;
  • Create the class with the correct namespace and extend Rits\Modular\ModuleDefinition;
  • Add App\Modules\Frontend\Module::class to the available array in the modular.php config file.

Restrictions

All module's controllers must be in a Controllers folder in the module main directory.

Roadmap

  1. Create a command to easily create a new module;
  2. Rewrite the README.md with better examples;
  3. Provide a example repository.
Comments