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
Cookpad TechConf 2019 〜霞が関〜 クックパッドiOSアプリの 破壊と創造...
Search
giginet
PRO
February 27, 2019
Technology
14
7k
Cookpad TechConf 2019 〜霞が関〜 クックパッドiOSアプリの 破壊と創造、そして未来
https://techconf.cookpad.com/2019/
giginet
PRO
February 27, 2019
Tweet
Share
More Decks by giginet
See All by giginet
Creating Intuitive Developer Tool in Swift
giginet
PRO
0
1.1k
Mergeable Libraryで 高速なアプリ起動を実現しよう!
giginet
PRO
2
4.4k
5分でわかるExplicitly Built Modules
giginet
PRO
0
630
Introduction for Open Source Swift Workshop
giginet
PRO
0
1.5k
Swift Packageを使った 巨大な依存グラフのキャッシュ戦略
giginet
PRO
5
5k
Deep Dive into Mergeable Library
giginet
PRO
1
1.8k
Go beyond the Actor Boundary ~ Swift 6へのConcurrency対応 ~
giginet
PRO
1
3.4k
新しいビルドツールScipioのご紹介
giginet
PRO
3
1.1k
ポケモンで学ぶiOS 16弾丸ツアー 🚅
giginet
PRO
1
940
Other Decks in Technology
See All in Technology
MLOps の現場から
asei
6
630
Oracle Cloud Infrastructure:2024年12月度サービス・アップデート
oracle4engineer
PRO
0
170
レンジャーシステムズ | 会社紹介(採用ピッチ)
rssytems
0
150
Amazon Kendra GenAI Index 登場でどう変わる? 評価から学ぶ最適なRAG構成
naoki_0531
0
100
私なりのAIのご紹介 [2024年版]
qt_luigi
1
120
watsonx.ai Dojo #5 ファインチューニングとInstructLAB
oniak3ibm
PRO
0
160
権威ドキュメントで振り返る2024 #年忘れセキュリティ2024
hirotomotaguchi
2
730
10個のフィルタをAXI4-Streamでつなげてみた
marsee101
0
160
ゼロから創る横断SREチーム 挑戦と進化の軌跡
rvirus0817
2
260
Snowflake女子会#3 Snowpipeの良さを5分で語るよ
lana2548
0
220
あの日俺達が夢見たサーバレスアーキテクチャ/the-serverless-architecture-we-dreamed-of
tomoki10
0
420
サイバー攻撃を想定したセキュリティガイドライン 策定とASM及びCNAPPの活用方法
syoshie
3
1.2k
Featured
See All Featured
Facilitating Awesome Meetings
lara
50
6.1k
Designing Experiences People Love
moore
138
23k
StorybookのUI Testing Handbookを読んだ
zakiyama
27
5.3k
Building Applications with DynamoDB
mza
91
6.1k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
Faster Mobile Websites
deanohume
305
30k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
0
96
Dealing with People You Can't Stand - Big Design 2015
cassininazir
365
25k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
5
440
Adopting Sorbet at Scale
ufuk
73
9.1k
Transcript
@giginet ϞόΠϧج൫෦ ʙբ͕ؔʙ ΫοΫύουiOSΞϓϦͷ ഁյͱɺͦͯ͠ະདྷ
2 ࠷ॳͷίϛοτ ݄ ݱࡏ·Ͱͷίϛοτ ϦϦʔεස िճ ϦϦʔεลΓͷ։ൃऀ d
૯ίʔυߦ ˞ݱࡏͷίʔυϕʔεʹҠߦޙ
3 ։ൃऀ͝ͱͷ1ͷྦྷੵϏϧυ࣌ؒ 1h 1.5h
4 27% 73% 155,000ߦ 58,700 ߦ Objective-C Swift
՝ 5 •1ྦྷੵ1࣌ؒ/ਓΛ্ճΔϏϧυ࣌ؒ •ࠓͳ͓25%͋ΔObjective-C •ϝϯς͞Εͯͳ͍ػೳ •ີ݁߹ա͗ͯͲ͔͜ม͑ΔͱյΕΔ
6 բ͕ؔ IUUQTKBXJLJQFEJBPSHXJLJ&##%&#$"&"%#&#"#&"
բ͕ؔͷత 7 •ίʔυཧ •Objective-Cͷഁյ •Ϗϧυ࣌ؒͷվળ
ཧ 8 .PEVMFT %ZOBNJD'SBNFXPSL "QQMJDBUJPO
ݱ࣮
ϚϧνϞδϡʔϧԽ 10 •Ωϟογϡ͕ޮ͖ɺ։ൃ࣌ͷϏϧυߴԽ •ݹ͍࣮ͷӅṭ •ը໘ؒΛૄ݁߹ʹͰ͖Δ
Objective-C Bridging 11 11 MyApp-Bridging-Header.h MyApp-Swift.h
բ͕ؔͷΰʔϧ 12 •։ൃऀͷखݩͷϏϧυ࣌ؒΛ130ҎʹೲΊΔ •Objective-CΛશʹফ͠ڈΔ
։ൃऀͷੜ࢈ੑΛ ͳΜͱ͔͢Δͷ͕ բ͕ؔ
View Model ViewController
15 View Model ViewController ϩδοΫΛ࣋ͭ7JFX XXXManager γϯάϧτϯͷσʔλιʔε .BTTJWF7JFX$POUSPMMFS ڞ௨Խ͞ΕͯංେԽͨ͠Ϟσϧ ☠
σουίʔυ ີ݁߹ 7JFXͷܧঝɺ͍ճ͠ ৮ͬͯ ͍͚ͳ͍ͭ ࠞಱ
DataStore UseCase Presenter ViewBuilder View Wireframe Entity DataStore Entity UseCase
Interactor Presentation Layer Domain Layer Data Layer Repository $PPLQBE7*1&3
17 Tsukuru Cookpad 7*1&3ԽҎલͷ.7$ 0CKFDUJWF$ 4XJGUͷࠞࡏ 7*1&3Խޙͷը໘ͷू߹ 4XJGU ɾɾɾ ࠞಱ
Cookpad
18 Tsukuru Cookpad 7*1&3ԽҎલͷ.7$ 0CKFDUJWF$ 4XJGUͷࠞࡏ 7*1&3Խޙͷը໘ͷू߹ 4XJGU ɾɾɾ 7*1&3ΞϓϦέʔγϣϯ
Cookpad
طଘͷΞʔΩςΫνϟΛ ੜ͔ͨ͠ ϚϧνϞδϡʔϧԽ
20
21 YAML yonaskolb/XcodeGen ࣗಈੜ
22 ৽نλʔήοτ
23 targets: CookpadCore: type: framework platform: iOS sources: - CookpadCore
settings: base: PRODUCT_BUNDLE_IDENTIFIER: com.cookpad.CookpadCore scheme: testTargets: - CookpadCoreTests dependencies: - sdk: Foundation.framework - carthage: Result - carthage: RxCocoa - carthage: RxSwift
24 σΟϨΫτϦߏʹΑΓ ॴଐ͢ΔϏϧυλʔήοτ͕ อূ͞ΕΔ
xcodeprojΛഁյͨ͠Β Ϟδϡʔϧಋೖ͕༰қʹ
ϚϧνϞδϡʔϧͷ ಋೖ 26
բ͕ؔͷίϯηϓτ 27 •େ͖ͳॻ͖͑Λڧ੍͠ͳ͍ •Objective-CΛ࣋ͪࠐ·ͤͳ͍ •࣮ৄࡉVIPERΞϓϦέʔγϣϯʹӅṭ
բ͕ؔͷίϯηϓτ 28 •େ͖ͳॻ͖͑Λڧ੍͠ͳ͍ •Objective-CΛ࣋ͪࠐ·ͤͳ͍ •࣮ৄࡉVIPERΞϓϦέʔγϣϯʹӅṭ
բ͕ؔͷίϯηϓτ 29 •େ͖ͳॻ͖͑Λڧ੍͠ͳ͍ •Objective-CΛ࣋ͪࠐ·ͤͳ͍ •࣮ৄࡉVIPERΞϓϦέʔγϣϯʹӅṭ
30 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C
31 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C
32 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C
33 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C
34 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C
35 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C ந
36 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Environment ۩ମతͳ࣮ ΠϯλʔϑΣΠεͷΈΛఏڙ
37 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Environment բ͕ؔήʔτΣΠ
38 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Bridging HeaderΛ ࣋ͨͳ͍
39 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Objective-C Bridge ΞϓϦͰ͚ͩ࣋ͭ
Objective-CΛ Έతʹഉআ SwiftԽͷ༏ઌॱҐΛՄࢹԽ
41 Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature B Feature
C Ӆṭ͍ͨ͠
42 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Environment ΠϯλʔϑΣΠεͷΈΛఏڙ
43 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Environment ݹ͍ϥΠϒϥϦͷґଘ ΞϓϦͷΈ͕࣋ͭ ۩ମతͳ࣮
44 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Environment ݹ͍ϥΠϒϥϦͷґଘ ΞϓϦͷΈ͕࣋ͭ ۩ମతͳ࣮ ػೳͷ։ൃ࣌ʹݹ͍ϥΠϒϥϦΛ ҙࣝ͠ͳͯ͘ࡁΉΑ͏ʹ
45 APIClient.share Cookpad Tests 45 Method Swizzling API Stub
46 Environment CookpadEnvironment TestingEnvironment Cookpad Tests Network Logger ը໘ભҠ
47 CookpadCore CookpadComponent Cookpad ɾɾɾ Cookpad Tsukuru Feature A Feature
B Feature C Ҡߦத Ҡߦத
՝ 48 Bundle Dynamic Linking Time Tsukuruશഁյ Feature moduleҠߦ Ϟδϡʔϧؒͷґଘ
దͳϞδϡʔϧׂ୯Ґ ։ൃ৫ͷεέʔϧ Objective-Cશഁյ
͝ਗ਼ௌ ͋Γ͕ͱ͏͍͟͝·ͨ͠ !HJHJOFU