Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
KMM&Compose MutiPlatformで始めるクロスプラットフォーム開発
Search
akkiee76
June 21, 2023
Technology
1.6k
2
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
KMM&Compose MutiPlatformで始めるクロスプラットフォーム開発
potatotips #82 iOS/Android開発Tips共有会の発表資料です。
akkiee76
June 21, 2023
More Decks by akkiee76
See All by akkiee76
EmptyViewは本当に“空”なのか?
akkie76
0
41
Graph Art with Charts API – Beyond Data Visualization
akkie76
0
270
Meet the Translation API
akkie76
0
520
コードレビューで開発を加速させるAIコードレビュー
akkie76
1
790
Android Target SDK 35 (Android 15) 対応の概要
akkie76
0
6.2k
コードレビューを支援するAI技術の応用
akkie76
5
1.3k
オブジェクト指向コードレビューの新しいアプローチ
akkie76
3
10k
Jetpack Compose で Adaptive Layout に対応しよう
akkie76
0
1.3k
Observationではじめる値監視
akkie76
4
4.9k
Other Decks in Technology
See All in Technology
技術的負債から考える、AI時代のエンジニアリング投資 — ビズリーチの技術的負債と向き合った経験から、変更し続けられるソフトウェアを考える/ technical-debt-con2026
visional_engineering_and_design
3
3k
アプリをもっと"iOSアプリっぽく"する小さな工夫 / Small Touches That Make Your App Feel More Like an iOS App
matsuji
1
900
積み重なった技術負債への挑戦 〜初手としての全社ゴト化〜
techtekt
PRO
0
1.2k
aws-iot-platform-architecture-use-cases.pdf
ma2shita
0
160
絵ではじめるKubernetesセキュリティ
aoi1
3
580
日経電子版を支えていく Kasane Design System/fec_fukuoka
nikkei_engineer_recruiting
0
1.5k
ユーザー価値を届け続けるためにウォンテッドリーが大切にしている文化
kotaminato
0
160
10分で知る最近のOmarchy
komagata
0
330
Slack上でインフラをトラブルシュートする! Agentic Platform Engineeringの第一歩
teru0x1
4
1.7k
作品が生態系になった ─ Mini Tokyo 3D から世界へ
nagix
0
190
Genieを崇めよ
kameitomohiro
0
130
幾何アルゴリズムで なめらかなピン操作を / iOSDC Japan 2026 / smoothpin
kazumanagano
0
350
Featured
See All Featured
Mobile First: as difficult as doing things right
swwweet
225
10k
Rebuilding a faster, lazier Slack
samanthasiow
85
9.6k
Test your architecture with Archunit
thirion
2
2.4k
Git: the NoSQL Database
bkeepers
PRO
432
67k
The MySQL Ecosystem @ GitHub 2015
samlambert
251
13k
Applied NLP in the Age of Generative AI
inesmontani
PRO
4
2.5k
Joys of Absence: A Defence of Solitary Play
codingconduct
1
520
Chasing Engaging Ingredients in Design
codingconduct
0
310
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
YesSQL, Process and Tooling at Scale
rocio
174
15k
ラッコキーワード サービス紹介資料
rakko
1
4.9M
Balancing Empowerment & Direction
lara
6
1.3k
Transcript
potatotips #82 ©2023 RAKUS Co., Ltd. KMM & Compose MultiPlatformで
始めるクロスプラットフォーム開発 @akkiee76 potatotips #82 iOS/Android開発Tips共有会
potatotips #82 Akihiko Sato / 株式会社ラクス Lead Engineer / @akkiee76
SaaS 開発 (Backend, Frontend) / Mobile 開発 (iOS, Android) 上流工程、コードレビュー、チームの課題改善など コールドブリューコーヒー☕ / パン作り🍞 / あんバターフランス🥐 自己紹介
potatotips #82 今日伝えたいこと KMM & Compose MultiPlatform を導入したクロスプラットフォーム開発の紹介
potatotips #82 Kotlin Multiplatform for Mobile (KMM) JetBrainsが開発したKotlinベースのクロスプラットフォーム 開発フレームワーク。1つの共通のKotlinコードベースを使用して、 iOSとAndroidの両方のプラットフォーム向けにネイティブアプリを
開発することができる点が特徴。
potatotips #82 Kotlin Multiplatform for Mobile (KMM) フレームワークイメージ
potatotips #82 Kotlin Multiplatform for Mobile (KMM) アーキテクチャイメージ Compose Multiplatform
potatotips #82 Compose MultiPlatform Compose Multiplatformは、Kotlinを使用して複数のプラットフォーム間でUI を共有するための宣言的なフレームワークです。JetBrainsとオープンソースの貢献 者によって開発され、Jetpack Composeに基づいています。 https://github.com/JetBrains/compose-multiplatform
potatotips #82 ここからは導入手順を紹介します
potatotips #82 開発に必要な環境 ・ macOS ・ Android Studio ・ Xcode
・ JDK ・ Kotlin Multiplatform Mobile plugin ・ Kotlin plugin ・ CocoaPods dependency manager あとは brew install kdoctor を実行するだけ
potatotips #82 プロジェクト作成 * Desktop版はIntelliJから作成可能
potatotips #82 プロジェクト構成
potatotips #82 commonMainに定義されている共通コード
potatotips #82 実際に利用したライブラリなど ・ Navigation ・ Network ・ DI (時間の関係上3つ紹介)
potatotips #82 Navigation 自分の実装イメージはこんな感じでしたが・・・。
potatotips #82 Navigation サポートされていなかった。。 https://github.com/JetBrains/compose-multiplatform/tree/master/tutorials/Navigation
potatotips #82 Navigation とりあえず自前で実装(Android)
potatotips #82 Navigation とりあえず自前で実装(iOS) * main.ios.ktも定義が必要です。
potatotips #82 Network Ktrofitライブラリを 導入して実装 RetrofitのようなAPIで 実装することが可能 https://foso.github.io/Ktorfit/
potatotips #82 Network レスポンスをselializeするため、 kotlinx-serializationも同時に導入 します。 https://github.com/Kotlin/kotlinx.serialization
potatotips #82 DI (Dependency Injection) 〜 module 定義 Koin(InsertKoinIO)を導入して実装 https://insert-koin.io/docs/reference/koin-mp/kmp/
potatotips #82 DI (Dependency Injection) 〜 Android 編
potatotips #82 DI (Dependency Injection) 〜 iOS 編
potatotips #82 まとめ ・ ComposeでViewを共通で利用できるため、 生産性の向上、保守性に期待できる ・ Kotlinで実装する共通ロジックは、柔軟に設計ができる ・ Android、iOS
両方のアーキテクチャの知見が必要 ・ まだまだ使い勝手が悪い点もあるが今後のアップデートに期待!
potatotips #82 ご静聴ありがとうございました