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
Backend-Driven UI: Making Screens Dynamic
Search
yhkaplan
October 16, 2020
Programming
1.9k
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Backend-Driven UI: Making Screens Dynamic
yhkaplan
October 16, 2020
More Decks by yhkaplan
See All by yhkaplan
Using the latest UICollectionView APIs
yhkaplan
0
3.5k
Swift and Concurrency: The Plan for World Domination
yhkaplan
0
220
Migrating from UIKit to SwiftUI efficiently
yhkaplan
4
3.9k
Property Wrappers
yhkaplan
0
620
Parser Combinators
yhkaplan
0
320
The Great Swift Migration
yhkaplan
1
4.3k
Speeding Up Your CI
yhkaplan
0
520
Automate All the Things
yhkaplan
4
2.7k
Other Decks in Programming
See All in Programming
Laravelのアプリケーションをどこにデプロイするか #ツナギメオフライン.9
akase244
0
110
MySQLとPostgreSQLって何が違うの?
akagami
PRO
0
160
AI時代に学ぶ 好きなルール 嫌いなルール Linter編
shorty5121
0
810
이 함수, 실패하면 어떻게 되나요? null부터 Rich Errors까지, Kotlin 에러 처리 15년
haeti2
0
120
LoopHub - ローカルで動く GitHub で、AI と共同開発
jugyo
0
390
FDEとは、何者なのか?
masapyon1212
0
130
The Good Stuff, Not the Slop: Engineering High-Quality Android Apps with Modern AI Tooling
danybony
0
150
バグを直したら useEffect が消えた
colorful12
3
830
PyO3 で既存 Python 評価器を Rust core 化する ー wasm-bindgen でブラウザにも配るための設計
kdash
1
360
XHTMLが残したもの
yosuke_furukawa
PRO
1
380
AI に Inclusive UI を書かせよう — Design Rules Skill で Compose UI を作り直す
theoriatec2024
1
430
「つくるAI」だけではバグは見つからない ~テストに必要な「見つけるAI」を分離させる戦略~
mfunaki
0
230
Featured
See All Featured
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
570
Claude Code のすすめ
schroneko
67
230k
How to build an LLM SEO readiness audit: a practical framework
nmsamuel
1
890
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
340
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
260
Designing for Timeless Needs
cassininazir
1
470
We Are The Robots
honzajavorek
0
330
Stop Working from a Prison Cell
hatefulcrawdad
274
21k
Designing for Performance
lara
611
70k
A Modern Web Designer's Workflow
chriscoyier
698
190k
The Pragmatic Product Professional
lauravandoore
37
7.4k
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
74
42k
Transcript
Backend-Driven UI: Making Screens Dynamic 1
Self-intro — Name: Joshua Kaplan (@yhkaplan) — Work: minne @
GMO Pepabo — Interests: ! CI/CD, " frameworks, and more — Hobbies: # bread, $ history, and running 2
What is a backend driven UI? — Extreme end: every
individual view defined by backend — Less extreme: order of and type of view defined by backend — Why JSON? 3
Purpose — Change content for each customer — A/B testing
— Feature flags — Less work to make changes 4
Demo 5
How I made it — Prototype in sample app —
Use compositional layout and diffable data sources — Define each section type as JSON w/ a title and subtitle — Firebase Remote Config 6
Code Example let homeReducer = Reducer<HomeState, HomeAction, HomeEnvironment> { state,
action, environment in switch action { case .loadSectionData: state.isSectionLoading = true return environment.homeService.homeContentPublisher() .replaceError(with: []) .receive(on: DispatchQueue.main) .map { HomeAction.loadItemData(sections: $0) } .eraseToEffect() case let .loadItemData(sections): state.isSectionLoading = true return environment.homeService.sectionItemsPublisher(sections: sections) .replaceError(with: [:]) .receive(on: DispatchQueue.main) .map { HomeAction.setSections(sections: $0) } .eraseToEffect() } return .none } 7
Challenges/risks — App Review risks (AKA don’t pull a Fortnite)
— Server unavailable 8
Other possible approaches — Defining more in JSON — microsoft/AdaptiveCards
— spotify/HubFramework — Web views 9
Conclusion — Easy to strike a balance w/ compositional layout
— Think of important, frequently changing screens — Worth it for minne — Try it out in a prototype! — yhkaplan/Shop 10