From 624df047e72062806a0e4759c278b6a3f11b78e9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20Sessing=C3=B8?= Date: Sun, 11 Oct 2015 10:44:46 +0200 Subject: [PATCH] Update README.md --- README.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/README.md b/README.md index 39c0810..7252bf2 100644 --- a/README.md +++ b/README.md @@ -57,6 +57,17 @@ SimpleRouter::group(['prefix' => 'v1', 'middleware' => '\MyWebsite\Middleware\So SimpleRouter::group(['prefix' => 'services'], function() { SimpleRouter::get('/answers/{id}', 'ControllerAnswers@show'); + + // Resetful ressource + Router::ressource('/rest', 'ControllerRessource'); + + // Load the entire controller (where url matches method names - getIndex(), postIndex() etc) + Router::controller('/controller', 'ControllerDefault'); + + // Example of providing callback instead of Controller + SimpleRouter::get('/something', function() { + die('Callback example'); + }); }); });