Fatal error: Uncaught ArgumentCountError: Too few arguments to function Slim\App::__construct(), 0
passed in C:\xampp\htdocs\tutorial\public\index.php on line 4 and at least 1 expected in
C:\xampp\htdocs\tutorial\vendor\slim\slim\Slim\App.php:57 Stack trace: #0
C:\xampp\htdocs\tutorial\public\index.php(4): Slim\App->__construct() #1 {main} thrown in
C:\xampp\htdocs\tutorial\vendor\slim\slim\Slim\App.php on line 57
index.php:
<?php
use \Psr\Http\Message\ServerRequestInterface as Request;
use \Psr\Http\Message\ResponseInterface as Response;
use \Interop\Container\ContainerInterface as ContainerInterface;
require '../vendor/autoload.php';
$app = new \Slim\App();
$app->get('/print', function(Request $request, Response $response) {
echo 'Hello, world!';
});
$app->run();
?>