Existing ActivityViewController does not have Activity to open Safari. With KSsafariActivity you can introduce it with just a single line without any concern for developers.
To run the example project, clone the repo, and run pod install
from the Example directory first.
- Swift 3.0 or later
- iOS 8.0 or later
// Create a KSSafariActivity with title and url
let ksSafariActivity = KSSafariActivity(title: "open safari", url: URL(string: "https://yourUrl"))
// Passing to applicationActivities just transitions as usual
let activityViewController = UIActivityViewController(activityItems: [""], applicationActivities: [ksSafariActivity])
present(activity, animated: true, completion: nil)
KSSafariActivity is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'KSSafariActivity'
kohei1218, [email protected]
KSSafariActivity is available under the MIT license. See the LICENSE file for more info.