Created
March 31, 2021 18:28
-
-
Save Rashidium/18aaea039ebf99868f3303e1d131049b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/// AppLinkable's for deeplink navigation. | |
public protocol AppLinkable { | |
/// Returns AppLinkable if url is satisfied | |
/// - Parameter url: URL of deeplink | |
func getLinkable(_ url: URL) -> Self? | |
/// Returns OneLinkable if url is satisfied. | |
/// - Parameter payload: Push notification payload of the deeplink. | |
func getLinkable(payload: [AnyHashable: Any]) -> Self? | |
/// Routes deeplink with `AppLinkRoutable` conformance. | |
/// - Parameter router: Action to be taken when link is ready. | |
func link(from router: AppLinkRoutable) | |
} | |
public extension AppLinkable { | |
func getLinkable(payload: [AnyHashable: Any]) -> Self? { | |
return nil | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment