zpmlabs/laravel-package-quick-demo
zpmlabs/laravel-package-quick-demo is a compact Laravel package example for quickly understanding a minimal reusable package setup. It serves as a starter reference for package structure, service provider registration, and Composer integration in Laravel applications, ideal for developers prototypin...
.env, get stuck on a DB error" path into a single command: php artisan quick-demo:install blog-demo → open /quick-demo/blog-demo. That directly informs whether demo/onboarding experience gets roadmap capacity or stays ad-hoc.^0.1 dependency — but see the adoption risk below.blog-demo, not demo), package-scoped DB names, demo_-prefixed tables, /quick-demo/{key} route mounting, public/vendor/quick-demos/... assets. PM owns whether that convention becomes a published standard or stays a suggestion..env, config/database.php, or routes/web.php; never seed the default connection — are product-grade constraints. This gives us a defensible answer to "will your demo pollute my app?" which is the #1 objection in package trials.quick-demo:install and send us the URL"), QA bug reports, internal onboarding of new engineers, and marketplace/listing evaluation pages.quick-demo:list / install command usage and tie it to package composer require conversion and support-ticket volume.Consider adopting when:
examples/ structure maps cleanly onto that.DemoDefinition in a service provider and following the QuickDemo::connectionName() pattern in migrations, seeders, and models.0.1.x line and effectively single-maintainer risk, adoption should be a timeboxed pilot, not a platform bet.Look elsewhere (or wait) when:
For executives (one paragraph): Today, trying one of our Laravel packages means a page of manual setup — editing .env, wiring a database, copying files — and most evaluators quit before they see anything work. This package turns that into a single command and a URL. It's a small, scoped dependency that makes our packages tryable in about two minutes, which is the cheapest lever we have on adoption, pre-sales demo time, and support load. The cost is low and reversible; the main caveat is that the package is very young, so I recommend a timeboxed pilot on one package before standardizing.
For engineering (the substance):
DemoDefinition in the package's service provider (key, name, DB name, stub, migrations, seeders, routes, views, assets, storage, config, optional hooks). Users run php artisan quick-demo:list / show / install <key> --fresh --force. It provisions an isolated SQLite file under database/quick-demos/, registers a per-demo connection, runs migrations and seeders against that connection only, and mounts routes at /quick-demo/{key} with quick-demo.{key}. name prefixes..env, config/database.php, or routes/web.php; it does not create or seed tables on the default connection; routes, views, assets, storage, and config are all namespaced under the demo key; existing generated files are never overwritten without --force. That is exactly the blast-radius control we'd otherwise have to build and audit ourselves.examples/ folder; migrations, seeders, and models need one line each (QuickDemo::connectionName(...)) to stay on the demo connection. The package's own agent guide functions as an implementation checklist and validation runbook, which lowers integration risk and review time.0.1.x. Treat it as an early dependency: pin the version, isolate it behind our own thin DemoDefinition helper so a swap is cheap, and be prepared to fork. If it stalls, the pattern is small enough to internalize.How can I help you explore Laravel packages today?