Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

온보딩 - 로그인 디자인 & 기능 완성 #90

Closed
Prev Previous commit
Next Next commit
refactor #87: 카카오 로그인 세팅
  • Loading branch information
enebin committed Sep 2, 2023
commit 58cc61fa873ca4d68e0595ebb7f39e213b0c81c0
3 changes: 2 additions & 1 deletion Plugins/EnvPlugin/ProjectDescriptionHelpers/InfoPlist.swift
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ public extension Project {
"NSExceptionMinimumTLSVersion": "TLSv1.2",
],
]
]
],
"LSApplicationQueriesSchemes": ["kakaokompassauth", "kakaolink"]
]

static let baseUrlInfoPlist: [String: InfoPlist.Value] = [
Expand Down
17 changes: 12 additions & 5 deletions Projects/Keyme/Sources/KeymeApp.swift
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,6 @@ struct KeymeApp: App {
var body: some Scene {
WindowGroup {
RootView()
.onOpenURL(perform: { url in
if (AuthApi.isKakaoTalkLoginUrl(url)) {
AuthController.handleOpenUrl(url: url)
}
})
}
}
}
Expand Down Expand Up @@ -56,6 +51,18 @@ class AppDelegate: UIResponder, UIApplicationDelegate, UNUserNotificationCenterD
return true
}

func application(
_ app: UIApplication,
open url: URL,
options: [UIApplication.OpenURLOptionsKey : Any] = [:]
) -> Bool {
if (AuthApi.isKakaoTalkLoginUrl(url)) {
return AuthController.handleOpenUrl(url: url)
}

return false
}

func application(_ application: UIApplication, didRegisterForRemoteNotificationsWithDeviceToken deviceToken: Data) {
let tokenParts = deviceToken.map { data in String(format: "%02.2hhx", data) }
let token = tokenParts.joined()
Expand Down