From f245e21468582da80c91060bfc0836761031aa1e Mon Sep 17 00:00:00 2001 From: SteamPixel Date: Mon, 8 Feb 2021 10:54:37 +0100 Subject: [PATCH] Added arrow function example and description --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index ad82659..2390155 100644 --- a/README.md +++ b/README.md @@ -69,7 +69,7 @@ Route::add('/', function() { ## Use arrow functions Since PHP 7.4 you can also use arrow functions to output your content. So you can easily use variables from outside and you can write shorter code. -Please be aware that an Arrow function must always return a value. Therefore you cannot use `echo` here. +Please be aware that an Arrow function must always return a value. Therefore you cannot use `echo` directly in here. You can find an example in index.php. However, this is deactivated, as it only works from PHP 7.4. ```php