Skip to content

ReadabilityHoldings/ReadabilityActivity

Repository files navigation

ReadabilityActivity

ReadabilityActivity is a UIActivity class for launching and adding articles to the Readability iOS app.

iOS 6 introduced the "share sheet"—a simple native interface to launch actions. We've created a custom UIActivity that you can integrate into your app. Simply import the ReadabilityActivity class and icons to your project and wire it up:

// init Readability activity
ReadabilityActivity *rdb = [[ReadabilityActivity alloc] init];

// set up activity item / action. url is a NSURL
NSArray *activityItems = @[ReadabilityActivityAdd, url];

// init share sheet with app-specific activity
UIActivityViewController *shareSheet = [[UIActivityViewController alloc] initWithActivityItems:activityItems applicationActivities:@[rdb]];

// present the view controller, animated.
[self presentViewController:shareSheet
animated:YES
completion:^{
}];

The ReadabilityActivity class also includes an easy way to check that Readability is installed on a device. This method returns YES if the user is running Readability 1.2.2 or newer:

[ReadabilityActivity canPerformActivity]

About

ReadabilityActivity UIActivity allows a user to add an article / URL to their Readability reading list

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published