From 3b0c4b3b67d6ed5abc3919100572cdfd5798744b Mon Sep 17 00:00:00 2001 From: hashrock Date: Thu, 15 Sep 2022 22:00:25 +0900 Subject: [PATCH] chore: add a head component to generated project (#771) This PR adds a `` component to projects generated using `init.ts`. --- init.ts | 34 +++++++++++++++++++++------------- 1 file changed, 21 insertions(+), 13 deletions(-) diff --git a/init.ts b/init.ts index 9ed5f252..78e14753 100644 --- a/init.ts +++ b/init.ts @@ -93,22 +93,30 @@ await Deno.writeTextFile( IMPORT_MAP_JSON, ); -const ROUTES_INDEX_TSX = `import Counter from "../islands/Counter.tsx"; +const ROUTES_INDEX_TSX = `import { Head } from "$fresh/runtime.ts"; +import Counter from "../islands/Counter.tsx"; export default function Home() { return ( - - the fresh logo: a sliced lemon dripping with juice - - Welcome to \`fresh\`. Try updating this message in the ./routes/index.tsx - file, and refresh. -

- - + <> + + Fresh App + + + the fresh logo: a sliced lemon dripping with juice + + Welcome to \`fresh\`. Try updating this message in the ./routes/index.tsx + file, and refresh. +

+ + + ); } `;