liberusoftware / module-cms-hello
A trivial proof-of-concept Liberu CMS module that exercises the whole pipeline: descriptor, isolation, contract, service, event, route, migration, config, and tests.
Package info
github.com/liberusoftware/module-cms-hello
Type:liberu-module
pkg:composer/liberusoftware/module-cms-hello
Requires
- php: ^8.5
- filament/filament: ^5.11.0
- liberusoftware/module-cms-contracts: ^0.1
- liberusoftware/module-cms-core: ^0.1
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
This package is auto-updated.
Last update: 2026-11-14 19:55:22 UTC
README
Repository
Source, issues, and release history: https://github.com/liberusoftware/module-cms-hello
Composer package: https://packagist.org/packages/liberusoftware/module-cms-hello
A trivial proof-of-concept module. It exists to exercise the entire module pipeline end to end and to be the module CI enables, disables, and re-enables.
Non-foundational by design: the "disable any module and the app still boots" guarantee is verified against it.
What it demonstrates (the full §5 module contract)
- Descriptor —
HelloModule(keyhello). - Self-gating provider —
HelloServiceProviderextendsModuleServiceProvider. - Own contract + service —
GreeterInterfacebound toGreeter. - Cross-module event —
HelloGreeteddispatched over theEventBus. - Versioned API route —
GET /api/v1/hello/{name?}. - Migration —
hello_greetings. - Config —
config/hello.php(hello.greeting), publishable + merged. - Tests — unit + feature, including enable/disable.
Install
composer update liberusoftware/cms-hello php artisan migrate
Try it
GET /api/v1/hello/ada -> { "module": "hello", "message": "Hello, ada!" }
Config keys
| Key | Default | Purpose |
|---|---|---|
hello.greeting |
Hello, :name! |
Template; :name is substituted. |
Events
- Emits:
Liberu\Cms\Hello\Events\HelloGreeted(hello.greeted) — on every greeting. - Listens: none.
Public contracts
Liberu\Cms\Hello\Contracts\GreeterInterface— resolve to produce greetings.
Disable
app(\Liberu\Cms\Contracts\Module\ModuleManagerInterface::class)->disable('hello');
The route 404s and the provider goes inert; the rest of the app is unaffected.