runtime/laravel is a Laravel package for laravel runtime.
It currently has 18 GitHub stars and 43 downloads on Packagist (latest version 1.0.0).
Install it with composer require runtime/laravel.
Discover more Laravel packages by runtime
or browse all Laravel packages to compare alternatives.
Last updated
A runtime for Laravel.
If you are new to the Symfony Runtime component, read more in the main readme.
composer require runtime/laravel
The runtime will register automatically. You may "force" the runtime by defining
the environment variable APP_RUNTIME for your application.
APP_RUNTIME=Runtime\Laravel\Runtime
// public/index.php
use Illuminate\Contracts\Http\Kernel;
define('LARAVEL_START', microtime(true));
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
return function (): Kernel {
static $app;
if (null === $app) {
$app = require dirname(__DIR__).'/bootstrap/app.php';
}
return $app->make(Kernel::class);
};
// artisan
use Illuminate\Contracts\Console\Kernel;
define('LARAVEL_START', microtime(true));
require_once __DIR__.'/vendor/autoload_runtime.php';
return function (): Kernel {
static $app;
if (null === $app) {
$app = require __DIR__.'/bootstrap/app.php';
}
return $app->make(Kernel::class);
};