Bosia Bosia v0.8.11

Section Blog

Section blog — kartu daftar post, header post, pembungkus prosa dan baris post terkait.

Section blog untuk situs konten. Masing-masing adalah Svelte <section> mandiri selebar penuh yang dibangun hanya dari token semantik, sehingga gayanya berganti di setiap tema. Coba pengalih tema di atas preview.

Preview

Product

Shipping beats polishing

Why a released rough edge teaches you more than an unreleased perfect one.

Jeki Maulana

Jeki Maulana

6 min read

Desk with an open notebook and laptop

The fastest way to learn what a feature is worth is to put it in front of people who didn't build it. Polish delays that lesson; shipping collects it.

Rough edges are feedback magnets

Users forgive an honest rough edge far more readily than a missing capability. What they won't do is imagine the feature you kept on a branch.

A released rough edge teaches you more than an unreleased perfect one.

What we do instead

  • Ship the smallest slice that answers a real question.
  • Watch how it's used for a week before touching it again.
  • Polish only the paths people actually walk.

None of this is an argument against quality. It's an argument about sequence: quality earns its keep after usefulness is proven, not before.

Install

bun x bosia@latest add block blog/post-list
bun x bosia@latest add block blog/post-header
bun x bosia@latest add block blog/post-body
bun x bosia@latest add block blog/related

post-body menarik ui/typography untuk gaya prosanya.

Blok-bloknya

  • post-list — heading dan intro di atas tumpukan kartu post (tag, tanggal, judul, kutipan).
  • post-header — tag, tanggal, judul, kutipan, byline penulis dengan waktu baca dan gambar sampul.
  • post-body — artikel prosa 70ch; kirim string html, snippet children, atau biarkan prosa contohnya.
  • related — baris "lanjut membaca" berisi hingga tiga kartu post ringkas.

Penggunaan

<script lang="ts">
	import PostList from "$lib/blocks/blog/post-list/block.svelte";
</script>

<PostList />

Setiap blok membawa post contoh sehingga langsung tampil. Untuk data asli, kirim props: post-list dan related menerima posts (array { slug, title, excerpt, tag, date, datetime }), post-header menerima field post langsung, dan post-body menerima html. Tautan post menuju {base}/{slug}base default /blog. Pasang feature blog untuk tabel post berbasis database dengan server loader yang menghasilkan bentuk data ini.

post-body merender html tanpa escape — hanya kirim konten tepercaya (database milikmu), jangan pernah input pengguna.

Sumber

src/lib/blocks/blog/*/block.svelte