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
Thorben Primke - Leavering Your Android Knowled...
Search
droidcon Berlin
July 17, 2018
Programming
0
98
Thorben Primke - Leavering Your Android Knowledge To Boost Your Team’s Velocity With React Native
droidcon Berlin
July 17, 2018
Tweet
Share
More Decks by droidcon Berlin
See All by droidcon Berlin
Jon Markoff - Best practice for apps
droidcon_berlin_2018
0
170
Jon Markoff - Voice in the enterprise
droidcon_berlin_2018
0
53
Michael Jess - Enabling enterprise mobility with SAP
droidcon_berlin_2018
0
91
Ronen Sabag - Lean async code with Kotlin’s coroutines
droidcon_berlin_2018
0
44
Boris Farber & Nikita Kozlov - The_Build_Side_of_Android_App
droidcon_berlin_2018
0
170
Zan Markan - The state of Kotlin
droidcon_berlin_2018
0
63
Miquel Beltran - No More □ (tofu) Mastering Emoji on Android
droidcon_berlin_2018
0
110
Laurent Gasser & Jeremy Rochot - Sharing a success story - A low cost, Customer driven and co-developed Android EMM
droidcon_berlin_2018
0
210
Hoi Lam - Adding ML Kit to Android Things And some TensorFlow things
droidcon_berlin_2018
1
180
Other Decks in Programming
See All in Programming
Introduction to kotlinx.rpc
arawn
0
630
技術を根付かせる / How to make technology take root
kubode
1
240
iOSエンジニアから始める visionOS アプリ開発
nao_randd
3
120
『GO』アプリ バックエンドサーバのコスト削減
mot_techtalk
0
130
知られざるDMMデータエンジニアの生態 〜かつてツチノコと呼ばれし者〜
takaha4k
4
1.3k
密集、ドキュメントのコロケーション with AWS Lambda
satoshi256kbyte
0
170
法律の脱レガシーに学ぶフロントエンド刷新
oguemon
5
730
ASP. NET CoreにおけるWebAPIの最新情報
tomokusaba
0
360
AWS Lambda functions with C# 用の Dev Container Template を作ってみた件
mappie_kochi
0
240
CNCF Project の作者が考えている OSS の運営
utam0k
5
690
第3回 Snowflake 中部ユーザ会- dbt × Snowflake ハンズオン
hoto17296
4
360
Kanzawa.rbのLT大会を支える技術の裏側を変更する Ruby on Rails + Litestream 編
muryoimpl
0
220
Featured
See All Featured
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
We Have a Design System, Now What?
morganepeng
51
7.4k
It's Worth the Effort
3n
184
28k
Producing Creativity
orderedlist
PRO
343
39k
jQuery: Nuts, Bolts and Bling
dougneiner
63
7.6k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
The Myth of the Modular Monolith - Day 2 Keynote - Rails World 2024
eileencodes
20
2.4k
Unsuck your backbone
ammeep
669
57k
For a Future-Friendly Web
brad_frost
176
9.5k
A designer walks into a library…
pauljervisheath
205
24k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
49
2.3k
Building Adaptive Systems
keathley
40
2.4k
Transcript
None
Leavering Your Android Knowledge To Boost Your Team’s Velocity With
React Native 6/27/2018 Thorben Primke Droidcon Berlin
Thorben Primke Product Engineer Pinterest @tprimke
Agenda Background Technical Aspects Current State & What’s Next 1
2 3
React Native React for building mobile application • Developed by
Facebook • Uses JavaScriptCore for processing the JS • Renders natively • Extensible
Our Interest What sparked the exploration • Product Engineering •
Growth Engineering • Business value • Piece wise adoption
Build Times Almost no more waiting • Android - 30sec
to multiple minutes • RN - Instant reloads
Context Less Lost In Translation • Efficient communication • One
Engineer for Web & Mobile • PM, design and engineer • Fewer inconsistencies
Foundation Starting Fresh vs Extending • Greenfield • Brownfield
But really… …is there no other way • Server Driven
UI • Hire more mobile engineers • Adds complexity to infrastructure
The Team Thorben Primke Product Engineer @tprimke Vivian Qu
Growth Engineer @vivqu Michael Schneider Core Experience Engineer @maicki
Agenda Background Technical Aspects Current State & What’s Next 1
2 3
New Home Where to keep the shared code • Android
and iOS in separate repositories • Separate repository for RN • Symlink into mobile repositories
Dependencies Frictionless integration • Leverage Maven • React Native is
already in local maven • Every other library needs the same
Dependencies Frictionless integration • Leverage Maven • React Native is
already in local maven • Every other library needs the same
Dependencies Frictionless integration • Leverage Maven • React Native is
already in local maven • Every other library needs the same
But APK Size …let’s take a look • Split APK
by arch • Multi dex • Fresco already in codebase • Only armv7 and x86
Let’s Render …how to render your React • Fragment based
architecture • Full screen • One React screen / module, one fragment
Let’s Render …how to render your React • Fragment based
architecture • Full screen • One React screen / module, one fragment
Dynamic Typing …but we like static languages • Flow •
TypeScript • Typeahead & refactoring
Native <-> RN …how does it work? • JavaScriptCore •
React Native Bridge • Delayed initialization React Native Native Bridge
API Client …no duplicate networking logic • Expose the REST
methods • No auth token to pass around • Reuse logging
API Client …no duplicate networking logic • Expose the REST
methods • No auth token to pass around • Reuse logging
UI Components …how does it work? • Pinterest Design System
• Gestalt on web • Ported the majority to React Native
Images …sharing between RN and native • Bridge your native
ImageView • Share the same cache
Navigation Leave it to native • JS vs Native navigation
• Single screen approach • Flexible router
Navigation Leave it to native • JS vs Native navigation
• Single screen approach • Flexible router
Navigation Leave it to native • JS vs Native navigation
• Single screen approach • Flexible router
Localization Nothing out of the box • JS Libs •
ICU format • Modeled after Android strings.xml
Localization Nothing out of the box • JS Libs •
ICU format • Modeled after Android strings.xml
Localization Nothing out of the box • JS Libs •
ICU format • Modeled after Android strings.xml
Localization Nothing out of the box • JS Libs •
ICU format • Modeled after Android strings.xml
More Bridging …for all the important pieces • Context Logging
• Experiment Framework
Agenda Background Technical Aspects Current State & What’s Next 1
2 3
Ensuring Success …one screen at a time • A/A NUX
performance experiment • Pre-build meetings • Always frictionless
Ensuring Success …one screen at a time • 4+ screens
live in the app • Continued support • Technology supported
More Work …supporting non-fullscreen • Asynchronous JS layout • iOS
has support RCTSurfaceView • Starting work for Android • Next version of React Native
OTA Updates …or known as code push • Considered but
delayed • Useful even with weekly releases • Requires UI to be fully JS
© Copyright, All Rights Reserved, Pinterest Inc. 2018 Thorben Primke
- @tprimke