Example #1
0
 function render(View $view, Request $request, Response $response)
 {
     $rendered = $this->env->render($view->getTemplate(), $view->getModel());
     $response->write($rendered);
 }
 function render(View $view, Request $request, Response $response)
 {
     $response->write(json_encode($view->getModel()), "\n");
 }