yusukebe / sonik-blog

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Sonik Blog

Creating Blog with Sonik.

Stack

  • Sonik (Hono + Vite based framework)
  • Preact
  • Zod
  • Tailwind CSS
  • Cloudflare Pages
  • Cloudflare D1

Demo

SSR with Island:

Screen.Recording.2023-08-07.at.23.07.19.mov

HMR with Cloudflare Bindings:

Screen.Recording.2023-08-07.at.23.11.51.mov

Usage

Setup your local database:

mkdir -p .mf/d1/DB/
sqlite3 .mf/d1/DB/db.sqlite < blog.sql

Setup D1:

yarn wrangler d1 create sonik-blog
yarn wrangler d1 execute sonik-blog --file=./blog.sql

Edit wrangler.toml:

cp wrangler.sample.toml wrangler.toml
code wrangler.toml

Dev:

yarn dev

Build:

yarn build

Deploy:

yarn deploy

Author

Yusuke Wada https://github.com/yusukebe

License

MIT

Heavily inspired by fresh-blog by azukiazusa1

About


Languages

Language:TypeScript 81.7%Language:CSS 16.2%Language:JavaScript 2.1%