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
Nuxt i18n Experience Sharing
Search
LINE Developers Taiwan
PRO
August 19, 2020
Programming
14k
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Nuxt i18n Experience Sharing
Nuxt i18n 實戰經驗分享 @ v-tw #006
v-tw event:
https://vuejs.kktix.cc/events/v-tw-meetup-006
LINE Developers Taiwan
PRO
August 19, 2020
More Decks by LINE Developers Taiwan
See All by LINE Developers Taiwan
Zona Codex Community Meetup 分享
line_developers_tw
PRO
0
1.2k
Evan & Zona COSCUP 2026 分享
line_developers_tw
PRO
0
170
台大資管營企業參訪-Bowen Chen
line_developers_tw
PRO
0
80
2026TECHFRESH畢業分享會 - AI 時代的人生存檔點
line_developers_tw
PRO
0
3.1k
2026TECHFRESH畢業分享會 - 原生還是跨平台? App 開發踩坑實錄
line_developers_tw
PRO
0
3.1k
2026TECHFRESH畢業分享會 - 葬送的通靈師:化系統與用戶雜訊成行動訊號
line_developers_tw
PRO
0
3.1k
2026 TECHFRESH 畢業分享會 - AI-Native 重塑軟體工程與虛擬講師
line_developers_tw
PRO
0
3.1k
2026 TECHFRESH 畢業分享會 - 開發日常大解密!從領域驅動到企業級上線
line_developers_tw
PRO
0
3.1k
2026TECHFRESH畢業分享會 - Lightning Talk - E起 See See : 電商推薦讀心術? 數據說了算
line_developers_tw
PRO
0
3.1k
Other Decks in Programming
See All in Programming
Claude Codeを組織的に動かして月400PRを実現した話
happy_ryo
0
200
KotlinConf Extended South Korea 2026 Keynote
l2hyunwoo
0
130
リアルな遅延を測る仕様
kota_yata
1
130
FastAPI の並行処理モデルを完全に理解する
hoto17296
9
3.3k
信頼性の目標を誰も求めてない
shubox
0
450
コンパウンドプロダクト開発のためのローカルプロセスマネージャー再発明 #layerxgo
izumin5210
0
600
自動化したのに回らない テスト運用の壁―AI時代の品質責任と生産性
mfunaki
0
560
実装をデザインガイドラインに追従させるための取り組み / 260731-dip-mosh-design-system
dachi023
0
8k
Oxlintはいいぞ(続)
yug1224
1
500
レビュー履歴をAIに食わせて、 Compose移行を加速するs
shihochan
0
260
片田舎のおっさん、 Swift Buildのダイアモンド問題解決の不具合修正PRを出すが、解決方法がキャッシュをしないようにすることであり、ビルド時間が伸びると言われてマージされないので高速化もする/swiftbuild
yimajo
0
330
Go 1.27からのGODEBUG / Go 1.27 リリースパーティ #go127party
mazrean
0
270
Featured
See All Featured
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
260
How Fast Is Fast Enough? [PerfNow 2025]
tammyeverts
3
850
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
11
1k
Reality Check: Gamification 10 Years Later
codingconduct
0
2.3k
The Language of Interfaces
destraynor
162
27k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Six Lessons from altMBA
skipperchong
29
4.5k
Bootstrapping a Software Product
garrettdimon
PRO
306
120k
The Mindset for Success: Future Career Progression
greggifford
PRO
0
480
Un-Boring Meetings
codingconduct
0
400
Data-driven link building: lessons from a $708K investment (BrightonSEO talk)
szymonslowik
1
1.3k
The Director’s Chair: Orchestrating AI for Truly Effective Learning
tmiket
1
290
Transcript
Abel — LINE TODAY 前端工程師 2020.08.19 1X[W LQ 䋿䜗妿涢獤Ձ
Menu 1. Intro Nuxt i18n 5mins 2. Intro LINE TODAY
5mins 3. Our Problems 15mins 4. Q&A 5mins
Nuxt i18n Example
Nuxt i18n Set Locale
Nuxt i18n Lazy Load
LINE TODAY 4 Countries 2500 Messages 4 Languages
LINE TODAY Modules
LINE TODAY Async Component
Nuxt i18n lazy load 700 messages Poll Component Weather Component
Movie Component LINE TODAY i18n setup
Problem 1 Page speed
Problem 1 Page speed
Problem 1 Split Message /\.poll\./ title.poll.page /\.weather\./ info.weather.AQI /\.movie\./ bt.movie.book
poll_zh_TW.json 20 messages weather_zh_TW.json 50 messages movie_zh_TW.json 130 messages lang/zh_TW.json 700 messages 150 messages Others bt.copy
Problem 1 JSON size
Problem 1 JSON size
Problem 1 JSON size
Problem 1 JSON size Real case https://lin.ee/C2LF1Im
Problem 1 Split Message Nuxt i18n lazy load 700 messages
Poll Component Weather Component Movie Component poll_zh_TW.json 20 messages weather_zh_TW.json 50 messages movie_zh_TW.json 130 messages shared 150 messages
Problem 1 Async Component
Problem 1 Solution
Problem 1 Import Message
Problem 2 SSR
Problem 2 SSR import messages import component Async Component 1st
request 2nd request HTML with language Weather.vue Async Component HTML no language Weather.vue
Problem 2 Solution Nuxt Plugin Import 700 messages import 50
messages import component Async Component Weather.vue SSR CSR HTML with language
Problem 2 SSR Solution
Problem 2 SSR Solution
Problem 3 Shared: Module:
Problem 3 JSON vs JS literal Module: Nuxt i18n lazy
load:
Problem 3 Speed https://lin.ee/jtds26s
Problem 3 Create shared JS
Problem 3 Solution
Summary • Split big JSON into small pieces. • Only
import the messages the you need. • Server side: import the whole messages. • Client side: import messages on the fly. • Don’t use JS literal to save i18n message. Use JSON.
Example https://lin.ee/3VzyZnF nuxt-i18n-demo
Q&A
LINE TECH FRESH https://engineering.linecorp.com/zh-hant/blog/tech-fresh-2020/ 34
35