Leaflet Blog in Deno Fresh
at main 730 B view raw
1import PostList from "../islands/post-list.tsx"; 2import { Title } from "../components/typography.tsx"; 3import { getPosts } from "../lib/api.ts"; 4import { Layout } from "../islands/layout.tsx"; 5 6export const dynamic = "force-static"; 7export const revalidate = 3600; // 1 hour 8 9export default async function Home() { 10 const posts = await getPosts(); 11 12 return ( 13 <Layout> 14 <div class="p-8 pb-20 gap-16 sm:p-20"> 15 <div class="max-w-[600px] mx-auto"> 16 <Title class="font-serif-italic text-4xl sm:text-5xl lowercase mb-12"> 17 Knotbin 18 </Title> 19 20 <div class="space-y-4 w-full"> 21 <PostList posts={posts} /> 22 </div> 23 </div> 24 </div> 25 </Layout> 26 ); 27}