PHP code example of vojtechrichter / styx

1. Go to this page and download the library: Download vojtechrichter/styx 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/ */

    

vojtechrichter / styx example snippets


\Styx\Startup::boot($config, $db_config);



declare(strict_types=1);

fig.php');

$routes = [
  new \Styx\Routing\Route(
    '/',
    \Example\Controllers\HomeController::class,
    'process',
    'method::any'
  )
];

$styx_config = new \Styx\Config($routes, ENV);

\Styx\Startup::boot($styx_config);