1. Go to this page and download the library: Download solidframe/laravel library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
solidframe / laravel example snippets
// app/Application/Handler/PlaceOrderHandler.php
final readonly class PlaceOrderHandler implements CommandHandler
{
public function __invoke(PlaceOrder $command): void { /* ... */ }
}
// That's it. No registration needed.
$commandBus->dispatch(new PlaceOrder('order-123', 'customer-456'));
use SolidFrame\Laravel\Modular\ModuleServiceProvider;
final class InventoryServiceProvider extends ModuleServiceProvider
{
protected function module(): ModuleInterface
{
return new InventoryModule();
}
public function register(): void
{
parent::register();
// custom bindings...
}
}