{"action":"created","issue":{"url":"https://api.github.com/repos/slimphp/Twig-View/issues/21","labels_url":"https://api.github.com/repos/slimphp/Twig-View/issues/21/labels{/name}","comments_url":"https://api.github.com/repos/slimphp/Twig-View/issues/21/comments","events_url":"https://api.github.com/repos/slimphp/Twig-View/issues/21/events","html_url":"https://github.com/slimphp/Twig-View/issues/21","id":92624032,"number":21,"title":"Support for flash","user":{"login":"neilmillard","id":3050649,"avatar_url":"https://avatars.githubusercontent.com/u/3050649?v=3","gravatar_id":"","url":"https://api.github.com/users/neilmillard","html_url":"https://github.com/neilmillard","followers_url":"https://api.github.com/users/neilmillard/followers","following_url":"https://api.github.com/users/neilmillard/following{/other_user}","gists_url":"https://api.github.com/users/neilmillard/gists{/gist_id}","starred_url":"https://api.github.com/users/neilmillard/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/neilmillard/subscriptions","organizations_url":"https://api.github.com/users/neilmillard/orgs","repos_url":"https://api.github.com/users/neilmillard/repos","events_url":"https://api.github.com/users/neilmillard/events{/privacy}","received_events_url":"https://api.github.com/users/neilmillard/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-02T12:28:52Z","updated_at":"2015-07-03T12:06:17Z","closed_at":null,"body":"Not sure if this is covered in the missing helpers, should this support flash messages?\r\n"},"comment":{"url":"https://api.github.com/repos/slimphp/Twig-View/issues/comments/118330381","html_url":"https://github.com/slimphp/Twig-View/issues/21#issuecomment-118330381","issue_url":"https://api.github.com/repos/slimphp/Twig-View/issues/21","id":118330381,"user":{"login":"Melbournite","id":10149705,"avatar_url":"https://avatars.githubusercontent.com/u/10149705?v=3","gravatar_id":"","url":"https://api.github.com/users/Melbournite","html_url":"https://github.com/Melbournite","followers_url":"https://api.github.com/users/Melbournite/followers","following_url":"https://api.github.com/users/Melbournite/following{/other_user}","gists_url":"https://api.github.com/users/Melbournite/gists{/gist_id}","starred_url":"https://api.github.com/users/Melbournite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Melbournite/subscriptions","organizations_url":"https://api.github.com/users/Melbournite/orgs","repos_url":"https://api.github.com/users/Melbournite/repos","events_url":"https://api.github.com/users/Melbournite/events{/privacy}","received_events_url":"https://api.github.com/users/Melbournite/received_events","type":"User","site_admin":false},"created_at":"2015-07-03T12:06:17Z","updated_at":"2015-07-03T12:06:17Z","body":"It does, but you need to send it over to the template.\r\n\r\nFor example:\r\n    $app->flash->addMessage('flash', 'This is a message');\r\n    return $response->withStatus(302)->withHeader('Location', $app->router->pathFor('home'));\r\n\r\nThen in 'Home':\r\n    $messages = $this->flash->getMessage('flash');\r\n\r\nInclude it by rendering out 'messages' to twig):\r\n    return $this->view->render($response, 'template.twig', [\r\n        'flash' => $messages,\r\n    ]);    \r\n\r\nThen in template.twig:\r\n    {% if flash %}\r\n    {% for flash in flash %} <- if multiple."}}