onesite/laravel-module
Larablocks Analysis
onesite/laravel-module works with Laravel 7 (latest release v1.1.3, Dec 8, 2020), which reached end of life on Mar 3, 2021: no more fixes, even for security.
Recommendation checks
Not advisedNot advised: no release or commit in over 2 years.
- No release or commit in over 2 years
- Supports only Laravel 7, past end of life since Mar 3, 2021
- No release in the last 12 months (last: Dec 8, 2020)
- 116 downloads a month (needs 10,000)
- 0 GitHub stars (needs 100)
State
Likely abandoned- No release or commit in over 2 years.
- Last stable release: Dec 8, 2020.
- No releases in the last 12 months.
- First released: May 29, 2020.
- Monthly downloads: 116.
- 0 open issues on GitHub.
Data from Packagist and GitHub, checked by Larablocks on Nov 28, 2026.
| Install | |
|---|---|
composer require onesite/laravel-module |
|
| Latest Version: | v1.1.3 |
| PHP: | ^7.2 |
| Laravel: | 7 |
| License: | MIT |
| Last Updated: | Dec 8, 2020 |
| Links: | GitHub · Packagist |
Laravel artisan make:resource command
This package adds the php artisan make:module command, allowing
you to:
Generate a module create a model, migration, controller, routes and model factory in a single easy to use command.
This package serves as a way of very quickly getting an idea off the ground, reducing the time you need to spend setting up various parts of your application so that you can concentrate on the complexity.
Installation
Install MakeResource through Composer.
"require": {
"onesite/laravel-module": "~1.0"
}
Next, update your config/app.php to add the included service provider \OneSite\Module\ModuleGeneratorServiceProvider::class:
'providers' => [
//...
\OneSite\Module\ModuleGeneratorServiceProvider::class
],
And you're good to go.
Using the generator
From the command line, run:
php artisan make:module ModelName "attributes"
For the simplest example, let's create a new admin module:
php artisan make:module admin
This will create the following:
- modules\Admin\app\Http\Controllers\BaseController.php
- modules\Admin\app\Http\Controllers\ExampleController.php
- modules\Admin\resources\views/example.blade.php
as well as appending to:
- modules\Admin\routes.php
Copy to composer.json and run composer dump-autoload to register composer for module, example with module admin:
"autoload": {
"psr-4": {
"Module\\Admin\\": [
"modules/admin/app/"
]
}
}
Next, update your app/Providers/AppServiceProvider.php to add the included service provider
to your register function:
public function register()
{
$this->app->register(\Modules\ModuleName\Providers\AppServiceProvider::class);
}
Running tests
A full test suite is included. To execute the tests, from the package directory:
vendor/bin/phpunit tests/testMakeNewModule.php
Related Packages
This package will generate a Laravel Model based on your database table itself,...
Generate a model, migration, controller, routes and factory
Version History
| Version | Released | PHP | Laravel | License |
|---|---|---|---|---|
| v1.1.3 | ^7.2 | ^7.0 | MIT | |
| v1.1.2 | ^7.2 | ^7.0 | MIT | |
| v1.1.1 | ^7.2 | ^7.0 | MIT | |
| v1.1.0 | ^7.2 | ^7.0 | MIT | |
| v1.0.2 | ^7.2 | ^7.0 | MIT | |
| v1.0.0 | ^7.2 | ^7.0 | MIT |