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
Type-Safe i18n on RN
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
@hotchemi
June 22, 2018
Programming
1.2k
2
Share
Type-Safe i18n on RN
@hotchemi
June 22, 2018
More Decks by @hotchemi
See All by @hotchemi
kompile-testing internal
hotchemi
0
290
The things we’ve learned from iOS×React Native hybrid development
hotchemi
2
5.5k
React Nativeを活用したアプリ開発体制/sapuri meetup
hotchemi
3
8.2k
Navigation in a hybrid app
hotchemi
3
1.3k
PermissionsDispatcher × Kotlin
hotchemi
0
3.4k
kotlin compiler plugin
hotchemi
1
800
Rx and Preferences
hotchemi
2
170
Introducing PermissionsDispatcher
hotchemi
1
170
khronos
hotchemi
4
2k
Other Decks in Programming
See All in Programming
アーキテクチャモダナイゼーションとは何か
nwiizo
19
5.5k
Don't Prompt Harder, Structure Better
kitasuke
0
790
NakouPAY説明用
annouim0
0
270
Surviving Black Friday: 329 billion requests with Falcon!
ioquatix
0
1.1k
GitHubCopilotCLIをはじめよう.pdf
htkym
0
290
2026_04_15_量子計算をパズルとして解く
hideakitakechi
0
120
WebAssembly を読み込むベストプラクティス 2026年春版 / Best Practices for Loading WebAssembly (Spring 2026)
petamoriken
2
110
PicoRuby for IoT: Connecting to the Cloud with MQTT
yuuu
2
690
属人化しないコード品質の作り方_2026.04.07.pdf
muraaano
0
260
GoogleCloudとterraform完全に理解した
terisuke
1
160
PHPer、Cloudflare に引っ越す
suguruooki
1
110
実践CRDT
tamadeveloper
0
600
Featured
See All Featured
We Are The Robots
honzajavorek
0
220
Design in an AI World
tapps
1
200
Crafting Experiences
bethany
1
130
The Curse of the Amulet
leimatthew05
1
12k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
55
3.3k
Color Theory Basics | Prateek | Gurzu
gurzu
0
300
Producing Creativity
orderedlist
PRO
348
40k
Have SEOs Ruined the Internet? - User Awareness of SEO in 2025
akashhashmi
0
330
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
12
1.6k
SEO for Brand Visibility & Recognition
aleyda
0
4.5k
Thoughts on Productivity
jonyablonski
76
5.1k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
231
23k
Transcript
Type-Safe i18n on RN Quipper Limited @hotchemi
7/19 Thu 19:30~22:00
react-native-i18n user?!
• It’s OK, but... • key name can be long
and nested • gotta move around definition and code • can’t detect an error in compile time • “missing [key name] translation”
None
• quipper/react-native-i18n-ts • paired with TypeScript • inspired by R.java
mechanism • strong IDE support • compile time check
Demo
• Under the hood • Generate d.ts file from definition
• with TypeScript compiler API
declare module "react-native-i18n" { var fallbacks: boolean; var translations: {
[keys: string]: any; }; function t(key: "common.cancel", opts: { value: any; }): string; function t(key: "common.ok"): string; } // for json loading declare module "*.json" { const value: any; export default value; }
• Installation • yarn add -D react-native-i18n-ts • set “model”
and “outputDir” in package.json • tweak filesGlob in tsconfig.json • execute “yarn i18n-ts” command
Enjoy!