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
Universal Link on iOS
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Tachibana Kaoru
April 27, 2016
Programming
1
190
Universal Link on iOS
Tachibana Kaoru
April 27, 2016
Tweet
Share
More Decks by Tachibana Kaoru
See All by Tachibana Kaoru
GeoLocationAnchor and MKTileOverlay
toyship
0
360
Custom Group Activities
toyship
3
1.4k
Synchronized iPhones, Again!
toyship
2
1.6k
ARKit4.pdf
toyship
1
2.3k
Custom Gesture Recognizer on iOS
toyship
3
1.4k
HEVC Video with Alpha Channel
toyship
1
1.2k
RealityKit & Reality Composer
toyship
3
660
ARKit3
toyship
4
7.5k
UIViewPropertyAnimator and Easing
toyship
2
1.1k
Other Decks in Programming
See All in Programming
なるべく楽してバックエンドに型をつけたい!(楽とは言ってない)
hibiki_cube
0
140
Rust 製のコードエディタ “Zed” を使ってみた
nearme_tech
PRO
0
170
AIエージェント、”どう作るか”で差は出るか? / AI Agents: Does the "How" Make a Difference?
rkaga
4
2k
[KNOTS 2026登壇資料]AIで拡張‧交差する プロダクト開発のプロセス および携わるメンバーの役割
hisatake
0
280
Spinner 軸ズレ現象を調べたらレンダリング深淵に飲まれた #レバテックMeetup
bengo4com
1
230
LLM Observabilityによる 対話型音声AIアプリケーションの安定運用
gekko0114
2
430
Oxlint JS plugins
kazupon
1
890
QAフローを最適化し、品質水準を満たしながらリリースまでの期間を最短化する #RSGT2026
shibayu36
2
4.4k
今から始めるClaude Code超入門
448jp
8
8.6k
20260127_試行錯誤の結晶を1冊に。著者が解説 先輩データサイエンティストからの指南書 / author's_commentary_ds_instructions_guide
nash_efp
1
960
生成AIを使ったコードレビューで定性的に品質カバー
chiilog
1
260
Architectural Extensions
denyspoltorak
0
280
Featured
See All Featured
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
9
1.2k
Applied NLP in the Age of Generative AI
inesmontani
PRO
4
2k
What the history of the web can teach us about the future of AI
inesmontani
PRO
1
430
Building Applications with DynamoDB
mza
96
6.9k
How to Ace a Technical Interview
jacobian
281
24k
Responsive Adventures: Dirty Tricks From The Dark Corners of Front-End
smashingmag
254
22k
Bioeconomy Workshop: Dr. Julius Ecuru, Opportunities for a Bioeconomy in West Africa
akademiya2063
PRO
1
54
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.7k
Why Mistakes Are the Best Teachers: Turning Failure into a Pathway for Growth
auna
0
51
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
93
Highjacked: Video Game Concept Design
rkendrick25
PRO
1
290
Transcript
Universal Link 2016/04/20 @TachibanaKaoru
ࣗݾհ ौ୩ͷVOYAGE GROUPͰiOSΤϯδχ ΞΛ͍ͯ͠·͢ɻ Twitter/Vainglory : @TachibanaKaoru Blog : http://www.toyship.org/
Bouldering : 4ڃ ே࣌ؒ.jpͱ͍͏ΞϓϦΛͩͯ͠·͢ɻ
Universal Linkͱ from iOS9 » ࣗͷΞϓϦଞͷΞϓϦΛىಈ͢ΔεΩʔϜɻ » iOS෦ͷʢઃఆͨ͠ʣURL Link͔ΒΞϓϦΛىಈ͢Δ͜ͱ͕Ͱ͖ Δɻ
» ࠓ·ͰͷΧελϜURLεΩʔϜΛ͓͖͔͑Δػೳɻ » URL Schemeͷ߹ʹͦΕͧΕͷΞϓϦ͕͖ͳͷΛઃఆͰ͖Δ ͷͰɺΞϓϦؒͷॏෳͷةݥੑ͕͕͋ͬͨɺUniversal Linkͷ߹ʹ ɺDomain໊ʹґଘ͢ΔͨΊɺҰҙੑ͕୲อͰ͖Δɻ
Universal Link from Memo
Universal Link from Mail
Universal Link ΞϓϦ͕Πϯετʔϧ͞Ε͍ͯΔ߹ɺ ΞϓϦͰ։͘ɻ
Universal Link ΞϓϦ͕Πϯετʔϧ͞Ε͍ͯͳ͍ ߹ɺMobile SafariͰ։͘ɻ
ଞͷΞϓϦ͔Βͷ Universal Link » openURLͰىಈͨ͠߹ʹɺUniversal Link͕༗ޮʹͳΓ·͢ɻ » ͨͩ͠ɺurlΛ։͘ࡍʹSFSafariViewControllerɺWKWebViewɺ UIWebViewΛ͏ͱUniversal LinkແޮʹͳΓ·͢ɻ
» ҙࣝͷߴ͍ΞϓϦͩΊɻ
ࣗͷΞϓϦ͔Βͷ Universal Link ࣗͷΞϓϦ͔ΒopenURLΛͯ͠Universal Link͕༗ޮʹͳΓ· ͤΜɻʢMobile SafariͰ։͘ʣ
Mobile Safari͔Β » Mobile SafariͷΞυϨεόʔʹURLΛೖྗͨ͠߹ɺMobile SafariͷϦϯΫ͔ΒҠಈͨ͠߹ʹUniversal Link͖͖·ͤ Μɻ » GoogleͳͲͷݕࡧ݁Ռ͔ΒUniversal
Link͕༗ޮʹͳΓ·͢ɻ
ϢʔβʔͷબΛอଘ » ΞϓϦͰ։͔͘ɺMobile SafariͰ։͔͘બͰ͖Δػೳ͕͋Δɻ
ϢʔβʔͷબΛอଘ Mobile SafariͰUniversal LinkରԠͷ ϦϯΫΛݕࡧ݁Ռʹදࣔͯ͠ΈΔɻ
ϢʔβʔͷબΛอଘ Ұ୴Universal Linkͱͯ͠ΞϓϦͰ ։͔ΕΔ͕ɺӈ্ʹSafariͷϦϯΫΛ දࣔ͢Δɻ
ϢʔβʔͷબΛอଘ SafariͷϦϯΫΛબ͢ΔͱSafariͰ ։͖ɺҎޙSafariͰ։͘Α͏ʹͳΔɻ
Smart App Bannerͱͷҧ͍ » Universal LinkɺSmart App Bannerͱత͕ҟͳΔͨΊɺ྆ ํ࣮͢Δඞཁ͕͋Γ·͢ɻ »
Smart App BannerͰɺΞϓϦ͕Πϯετʔϧ͞Ε͍ͯͨΒΞϓϦ ͕ىಈ͞ΕɺΞϓϦ͕Πϯετʔϧ͞Ε͍ͯͳ͔ͬͨΒApp Store͕ ىಈ͢Δɻ <meta name="apple-itunes-app" content="app-id=400435286, app-argument=https://asajikan.jp/topics/">
Smart App BannerͱUniversal LinkͷӅΕ ͨؔ » Smart App Bannerͷcontentͷapp-argumentࢦఆ͕Universal LinkʹରԠ͍ͯ͠Δ͔Ͳ͏͔ͰUI͕มΘΔɻʢԼهͷϦϯΫΛ
Mobile SafariͰνΣοΫͯ͠Έ͍ͯͩ͘͞ʣ » https://asajikan.jp/ (Universal LinkରԠ) » https://asajikan.jp/topics/ (Universal LinkඇରԠ)
Smart App Banner Universal LinkରԠͷ߹ɺΞϓϦͰ Universal Linkͱͯ͠։͘ɻʢBanner খ͞Ίʣ
Smart App Banner Universal LinkରԠͷ߹ɺΞϓϦͷ τοϓΛ։͘ɻʢBannerେ͖Ίʣ
࣮ํ๏ » Server » Client
࣮ํ๏ (Server) » server root(/)ʹ apple-app-site-association ͱ͍͏໊শͰjson ϑΥʔϚοτͷઃఆϑΝΠϧΛஔ͘ɻ » ʢ͜ͷϑΝΠϧʹॺ໊Λ͔͚Δඞཁ͕͋Δͱ͍͏ใ͕͚͋ͬͨ
Ͳɺ͔͚Δඞཁ͋Γ·ͤΜɻʣ » iOS9.3.1Ҏ্Ͱɺapple-app-site-associationͷϑΝΠϧαΠζ 128KBʹ੍ݶ͞Εͯ·͢ɻ(9.3Ͱൃੜ͍ͯͨ͠ΫϥογϡͷݪҼ ͩͬͨΒ͍͠)
apple-app-site-association format » Bundle IdentifierͱUniversal LinkʹରԠ͍ͤͨ͞pathΛهड़ɻ { "applinks": { "apps":
[], "details": [ { "appID": "9JA89QQLNQ.com.apple.wwdc", "paths": [ "/wwdc/news/", "/videos/wwdc/2015/*"] }, { "appID": "ABCD1234.com.apple.wwdc", "paths": [ "*" ] } ] } }
࣮ํ๏ (Server) » ઃఆϑΝΠϧͷஔ͖ॴɺ9.3͔Β /.well-known/ αϙʔτ͢Δ Α͏ʹͳΓ·ͨ͠ɻ » Technical Q&A
QA1919 » Incoming requests for /.well-known/apple-app-site- association file https://developer.apple.com/library/ios/qa/qa1919/ index.html#//appleref/doc/uid/DTS40016874
apple-app-site-association format asajikan.jpͷݱࡏͷઃఆ { "applinks": { "apps": [], "details": [
{ "appID": "94VJUJ8B7P.jp.asajikan.www", "paths": [ "/", "/article/*", "/recipe/*" ] } ] } }
apple-app-site-association format » ࣮ɺࠓͷϑΥʔϚοτҎલʹΘΕ͍ͯͨݹ͍ϑΥʔϚοτ͋Γ ·͢ɻʢͦͷ͏ͪແޮʹͳΔͱࢥ͏ͷͰΘͳ͍΄͏͕Α͍ʣ { "applinks": { "apps": [],
"details": { "94VJUJ8B7P.jp.asajikan.www": { "paths": [ "/", "/article/*", "/recipe/*" ] } } } }
apple-app-site-association format » ?͕Ұจࣈɺ*͕ෳจࣈ » NOTΛͬͯର֎pathͷઃఆͰ͖Δ͕ɺݹ͍iOSͰඇରԠ ʢ9.2.1ͰOKɺ9.1ͰNGʣ » "paths": [
"/wwdc/news/", "NOT /videos/wwdc/2010/", "/ videos/wwdc/201?/"] » ͜͏͢Δͱɺwwdc/201*/ҎԼͷϑΝΠϧwwdc/2010Λͷ͍ͧ ͯUniversal LinkରԠͱͳΔɻ
App Search API Validation Tool » formatͷvalidation checkΛ͢Δ͜ͱ͕Ͱ͖·͢ɻ » https://search.developer.apple.com/appsearch-validation-
tool
None
࣮ํ๏ (Client) » ProjectͷCapabilityʹAssociated DomainsΛઃఆ » ྫʣDomains: applinks:asajikan.jp
None
࣮ํ๏ (Client) » ىಈ͞Εͨ࣌ͷϋϯυϦϯάॲཧ » UIApplicationDelegate » application:continueUserActivity:restorationHandler: » ʢCore
SearchHandoffʹΑΔىಈϋϯυϦϯά͢Δʣ
func application(application: UIApplication, continueUserActivity userActivity: NSUserActivity, restorationHandler: ([AnyObject]?) -> Void)
-> Bool{ if userActivity.activityType == "com.apple.corespotlightitem" { // Core SearchͷॲཧΛهड़ } else if userActivity.activityType == NSUserActivityTypeBrowsingWeb { let url : NSURL? = userActivity.webpageURL // Universal LinkͷॲཧΛهड़ } return true }
·ͱΊ » Web Site࿈ܞΞϓϦUniversal Linkಋೖ͖͢ » Smart App Banner࿈ܞͤ͞Δͱϕλʔ »
Universal LinkରԠpathࡉ͔͘ઃఆͰ͖Δ͕ɺiOSͷόʔδϣϯ ʹΑͬͯಈ࡞͕ҟͳΔ͜ͱʹҙ