<?php

use Illuminate\Support\Facades\Route;

Route::get('/', function () {
    return view('welcome');
});

Route::get('/check-session', function () {
    session(['test' => 'ok']);
    return response()->json([
        'csrf' => csrf_token(),
        'session' => session('test'),
    ]);
});
