twig = $twig; } protected function renderInlineCss(array $files) { $css = ''; foreach ($files as $file) { $css .= file_get_contents($file); } return ""; } protected function renderHtml(Request $request, Response $response, string $template, array $parameters = []): Response { // If the path ends in .json, return the parameters if ('.json' == substr($request->getUri()->getPath(), -5, 5)) { return $this->jsonResponse($parameters, $request, $response); } return $this->twig->render( $response, $template, $parameters ); } }