跳到內容

範例

每一章都附一個 30–80 行、可以單獨 git clone 跑起來的 demo,不依賴貫穿專案。 第 13 章(儲存選型)與第 43 章(總回顧)是參考與收尾,沒有對應範例。

Part 0 · 心智模型與工具鏈

  • ch01-isolate-model01. 為什麼是 Workers:isolate 不是「更快的 Lambda」4 檔
  • ch02-toolchain02. 工具鏈:Wrangler v4、wrangler.jsonc 與本機開發5 檔

Part 1 · Workers 核心

Part 2 · 資料層

  • ch08-kv08. Workers KV:最終一致性要怎麼用才對4 檔
  • ch09-d109. D1 入門:邊緣上的 SQLite6 檔
  • ch10-drizzle10. D1 + Drizzle ORM:型別安全的資料層10 檔
  • ch11-d1-replication11. D1 進階:Read Replication 與 Sessions API5 檔
  • ch12-r212. R2:零 egress 費用的物件儲存4 檔

Part 3 · 有狀態運算

Part 4 · 非同步與事件流

Part 5 · 全端與前端

Part 6 · 進階平台能力

Part 7 · AI

Part 8 · 工程實務