thereline / crudmaster
A Laravel package called CrudMaster that provides modular, flexible CRUD generation and response handling, tailored for both API and web (Inertia or Blade) apps.
Fund package maintenance!
elcomware.com/support
Requires
- php: 8.2 || 8.4.*
- illuminate/contracts: *
Requires (Dev)
This package is auto-updated.
Last update: 2025-08-26 16:18:22 UTC
README
CrudMaster by Elcomware is a premium Laravel package that helps you scaffold professional, scalable, and modern CRUD systems in minutes. It supports full-stack development โ from clean API endpoints to dynamic frontend-ready scaffolding for Inertia.js or Blade-based apps.
๐ Features
- โ๏ธ Instant CRUD generation (Model, Migration, Controller, Request, Policy, Routes)
- ๐จ Supports Blade or Inertia (Vue) UI stacks
- ๐งฉ JSON API-ready controllers with clean unified response
- ๐งฑ Custom stub system for flexible scaffolding
- ๐ Auto-register routes, views, and assets
- โ Unified response helpers (Success, Error, Validation)
- ๐งช Built-in test support & publishable config/assets
- ๐ฆ Laravel 10+ and 12+ ready
๐ฆ Installation
composer require elcomware/crudmaster
๐ง If using Laravel < 5.5, manually register the service provider:
// config/app.php 'providers' => [ CrudMaster\CrudMasterServiceProvider::class, ],
๐ Publish Assets
php artisan vendor:publish --tag=crudmaster-config # Configuration file php artisan vendor:publish --tag=crudmaster-views # Blade views php artisan vendor:publish --tag=crudmaster-stubs # Customizable stubs php artisan vendor:publish --tag=crudmaster-js # Inertia-compatible JS
โก Quick Start
Generate CRUD for a resource (e.g. Post
):
php artisan crudmaster:make Post
Options:
Option | Description |
---|---|
--inertia |
Generate Inertia + Vue scaffolding |
--api |
API-only controller |
--ui=blade |
Choose blade , inertia , or none |
--fields=name:string,email:string,age:integer |
Scaffold with fields |
--force |
Overwrite existing files |
๐ Response System
CrudMaster includes an intelligent response engine:
respond_success($payload, 'Component', ['extra'], 'Done', 'route.name'); respond_error('Something failed', 'redirect.back', ['details']); respond_info('FYI message...'); respond_validation_failure($errors);
๐ง Automatically detects:
- API (returns JSON)
- Inertia (returns Inertia::render)
- Blade (returns view or redirect)
โ๏ธ Config (config/crudmaster.php
)
return [ 'ui' => 'inertia', 'default_namespace' => 'App\\Http\\Controllers', 'response_class' => App\\Http\\Responses\\SuccessResponse::class, 'routes' => [ 'prefix' => 'admin', 'middleware' => ['web', 'auth'], ], ];
๐งช Testing
CrudMaster is ready for automated testing via Pest or PHPUnit.
php artisan test
๐ Folder Structure Overview
src/
โโโ Commands/
โโโ Generators/
โโโ Responses/
โโโ Stubs/
โโโ Helpers/
โโโ CrudMasterServiceProvider.php
๐ License
CrudMaster is open-source software licensed under the MIT license.
๐ฌ Support & Contributions
Need help? Found a bug? Want to contribute?
- Submit issues or PRs via GitHub
- Commercial/custom feature support: hello@elcomware.com
Your CRUD. Your Stack. Your Control โ with CrudMaster by Elcomware.