New

Just launched: Vueblocks, a brand-new search engine for Vue packages! Explore Vueblocks →

internachi/modularize

468,941 2
Install
composer require internachi/modularize
Latest Version:1.1.1
Laravel:10 – 13
License:MIT
Last Updated:Mar 23, 2026
Links: GitHub  ·  Packagist
Maintainer: inxilpro

Modularize

Traits for package authors to add internachi/modular support to their Laravel commands.

Installation

composer require internachi/modularize

Usage

Add the Modularize trait to your package commands:

use Illuminate\Console\Command;
use InterNACHI\Modularize\Support\Modularize;

class SomeCommand extends Command
{
    use Modularize;

    public function handle()
    {
        if ($module = $this->module()) {
            // Command was called with --module, $module is a ModuleConfig class
            // with name, base path, namespaces, and helper methods.
        }
    }
}

If you're using Laravel file generator commands, add the ModularizeGeneratorCommand trait:

use Illuminate\Console\GeneratorCommand;
use InterNACHI\Modularize\Support\ModularizeGeneratorCommand;

class MakeWidget extends GeneratorCommand
{
    use ModularizeGeneratorCommand;

    // ...
}

This adds a --module option to your command. When used, generated files are placed in the module directory with correct namespacing.

Related Packages

daniel-cintra/modular

A fast way to develop web apps using Laravel, Vue and Inertia.

4,350 176
sircumz/laravel-modular

A Laravel 5.4 package for a modular design.

14 2
provision/administration

Laravel administration

3,749 11
coduxe/modular-laravel

Laravel modular friendly

22 0
internachi/modular

Modularize your Laravel apps

1,270,952 1,214

Version History

Version Released Laravel License
1.1.1 ^10|^11|^12|^13|dev-main|dev-master MIT
1.1.0 ^10|^11|^12|dev-main|dev-master MIT
1.0.0 ^11|^12|dev-main|dev-master MIT