Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Hono v3 - Do Everything, Run Anywhere, But Smal...
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Yusuke Wada
January 24, 2023
Programming
1.2k
4
Share
Hono v3 - Do Everything, Run Anywhere, But Small, And Faster
About the next major version of Hono. "v3".
Yusuke Wada
January 24, 2023
More Decks by Yusuke Wada
See All by Yusuke Wada
飯MCP
yusukebe
0
560
へんな働き方
yusukebe
6
3k
Cap'n Webについて
yusukebe
0
340
OSS開発者の憂鬱
yusukebe
17
30k
r2-image-worker
yusukebe
1
260
Introduce Hono CLI
yusukebe
6
4.1k
私はどうやって技術力を上げたのか
yusukebe
47
21k
Reactをクライアントで使わない
yusukebe
8
7.1k
AI時代のUIはどこへ行く?
yusukebe
23
12k
Other Decks in Programming
See All in Programming
サークル参加から学ぶ、小さな事業の回し方
yuzneri
0
230
技術記事、AIに書かせるか、自分で書くか? 〜それでも私が自分の手で書く理由〜 / #QiitaConference
jnchito
2
280
1人1案件のプロダクトエンジニア時代に、"プロセス監督"としてチャレンジしたこと
non0113
0
300
How We Practice Exploratory Testing in Iterative Development( #scrumniigata ) / 反復開発の中で、探索的テストをどう実施しているか
teyamagu
PRO
3
1.1k
Transactional Change Stream Processing With Debezium and Apache Flink
gunnarmorling
1
120
過去のレビュー知見をSkillsで資産化した話
pkshadeck
PRO
1
2.3k
These Five Tricks Can Make Your Apps Greener, Cheaper, & Nicer
hollycummins
0
180
次世代リンターで探る、tsgo 時代における型認識カスタムルールの現実解
ytakahashii
1
960
ローカルLLMでどこまでコードが書けるか / How much code can be written on a local LLM
kishida
2
410
20260514 - build with ai 2026 - build LINE Bot with Gemini CLI
line_developers_tw
PRO
0
470
Agent Skills を社内で育てる仕組み作り
jackchuka
1
2.4k
iOS26時代の新規アプリ開発
yuukiw00w
0
200
Featured
See All Featured
A Soul's Torment
seathinner
6
2.8k
The B2B funnel & how to create a winning content strategy
katarinadahlin
PRO
1
360
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
140
Bash Introduction
62gerente
615
210k
GitHub's CSS Performance
jonrohan
1033
470k
Future Trends and Review - Lecture 12 - Web Technologies (1019888BNR)
signer
PRO
0
3.5k
VelocityConf: Rendering Performance Case Studies
addyosmani
333
25k
Measuring & Analyzing Core Web Vitals
bluesmoon
9
830
How to audit for AI Accessibility on your Front & Back End
davetheseo
0
380
Designing for Timeless Needs
cassininazir
1
230
Code Reviewing Like a Champion
maltzj
528
40k
What’s in a name? Adding method to the madness
productmarketing
PRO
24
4k
Transcript
Yusuke Wada 2023-01-24 Serverless Frontend Meetup Hono v3 Do Everything,
Run Anywhere, But Small, And Faster * will be released soon!
Me • Yusuke Wada • Supervisor at TravelBook Inc. •
Web developer, Web framework developer • https://yusukebe.com/ • https://github.com/yusukebe 2
Ultrafast web framework for Cloudflare Workers, Deno, Bun, and Node.js
3 What's Hono?
Without Hono
With Hono
6 Web frameworks/routers for Cloudflare Workers •itty-router ~550 bytes •Sunder
•Worktop •Hono
•Fast - 3+1 Routers •Tiny - about 20kB •Multi-runtimes -
CF, Fastly, Deno, Bun, Lagon, Node.js •Fine DX - TypeScript •Batteries Included - Middleware 7 Hono Features
•Deno •Deno Benchmark •cdnjs •Ultra - Deno/React SSR Framework •Cloud
fl are D1 example •substats •Kings League Project •react-starter-kit •Driv.ly 8 Who uses Hono?
Demo 1-minute deploy 9
Current version v2.7.5 shipped today 10
Going to "v3" Not released yet but will be soon.
11 Do Everything, Run Anywhere, But Small, And Faster
Run anywhere 12
13 Multi-runtimes CI support
Node.js support 14
Adapters 15 Cloud fl are Workers, Cloud fl are Pages,
Bun, Deno are available
Cloudflare Pages
`/functions` 17
Next.js Edge API Routes
Use middleware on Vercel 19
Anywhere! thanks to Web Standard • Cloud fl are Workers
• Cloud fl are Pages • Fastly Compute@Edge • Deno • Bun • Lagon • Vercel • Node.js • ... 20 Hono may work on every JavaScript runtime!
Faster 21
Performance improvement 22 15% faster! 3% slower:( Using https://github.com/SaltyAom/bun-http-framework-benchmark Measured
on 2023-01-22
Small 23
A little fatter, but still small. 24 Express => 572
kB Fastify => 1.2 MB
[email protected]
=> 48 kB
Pico - Ultratiny web framework 25 https://github.com/yusukebe/pico May be placed
on @hono/pico ??
Do everything 26
RPC mode - like tRPC but integrated, too simple 27
1. Server: Write the schema 28
2. Use `zod-validator` Middleware 29
3. Write the endpoint with `jsonT()` and `build()` 30
4. Export "types" 31
5. Client: Use `@honoj/hc` and import "types" 32
6. Post JSON and parse the response 33
Share the API specs 34
Demo: https://github.com/honojs/hono/issues/727#issuecomment-1369078973 35
Great 👍 36
`create hono` command 37
@honojs to `@hono` ! 38 • We can make packages
such middleware as `@hono/xxx` • Middleware • @hono/zod-validator • @hono/qwik-city • @hono/graphql-server - by @metrue • @hono/sentry by @sam-lippert • @hono/ fi rebase-auth by @Code-Hex • @hono/node-server • @hono/hc
Ecosystem 39 Hono Middleware hc node-server Adapter Pico `create hono`
@hono/qwik-city 40 Works on Cloud fl are Workers and Bun
(also on Deno?)
It works on your runtime if it works on Hono
41
Others • `HonoRequest` • `HTTPException` • Router - regexp with
slash support 42
Hono v3 will be released soon! 43