1. Go to this page and download the library: Download louzet/zenora 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/ */
louzet / zenora example snippets
use Zenora\Attribute\Command;
use Zenora\Attribute\Option;
use Zenora\Context;
use Zenora\Zenora;
#[Command('app:hello', description: 'Say hello')]
class HelloCommand {
public function handle(
Context $ctx,
#[Option(shortcut: 'n')] string $name = 'World'
): void {
$ctx->success("Hello $name!");
}
}
Zenora::forge()
->register(HelloCommand::class)
->ignite($argv);