Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/0x0c/m2dwebviewcontroller

Simple built-in web view controller using WebKit.
https://github.com/0x0c/m2dwebviewcontroller

ios ios-app ios-lib objective-c webkit

Last synced: about 7 hours ago
JSON representation

Simple built-in web view controller using WebKit.

Awesome Lists containing this project

README

        

# M2DWebViewController

[![CI Status](http://img.shields.io/travis/Akira/M2DWebViewController.svg?style=flat)](https://travis-ci.org/Akira/M2DWebViewController)
[![Version](https://img.shields.io/cocoapods/v/M2DWebViewController.svg?style=flat)](http://cocoadocs.org/docsets/M2DWebViewController)
[![License](https://img.shields.io/cocoapods/l/M2DWebViewController.svg?style=flat)](http://cocoadocs.org/docsets/M2DWebViewController)
[![Platform](https://img.shields.io/cocoapods/p/M2DWebViewController.svg?style=flat)](http://cocoadocs.org/docsets/M2DWebViewController)

![](https://raw.github.com/0x0c/M2DWebViewController/master/images/1.png)
![](https://raw.github.com/0x0c/M2DWebViewController/master/images/2.png)
![](https://raw.github.com/0x0c/M2DWebViewController/master/images/3.png)

## Usage

To run the example project, clone the repo, and run `pod install` from the Example directory first.

Try this

M2DWebViewController *viewController = [[M2DWebViewController alloc] initWithURL:[NSURL URLWithString:@"https://github.com/0x0c/M2DWebViewController"]

or this

M2DWebViewController *viewController = [[M2DWebViewController alloc] initWithURL:[NSURL URLWithString:@"https://github.com/0x0c/M2DWebViewController"]];
__weak typeof(viewController) bviewcontroller = viewController;
viewController.actionButtonPressedHandler = ^(NSString *pageTitle, NSURL *url){
UIActivityViewController *activityViewController = [[UIActivityViewController alloc] initWithActivityItems:@[pageTitle, url] applicationActivities:@[]];
[bviewcontroller presentViewController:activityViewController animated:YES completion:^{
}];
};

## Requirements
iOS 12 or later.

## Installation

M2DWebViewController is available through [CocoaPods](http://cocoapods.org). To install
it, simply add the following line to your Podfile:

pod "M2DWebViewController"

## Author

Akira Matsuda, [email protected]

## License

M2DWebViewController is available under the MIT license. See the LICENSE file for more info.