JGHybrid
Example
To run the example project, clone the repo, and run pod install
from the Example directory first.
Requirements
JGWebKitURLProtocol
JGNavigationBarTransition
SSZipArchive
Installation
JGHybrid is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'JGHybrid'
How To Use
let vc:HybridViewController = Hybrid.load(urlString: "http://web-qa.doctorwork.com/rapp/health/health-package/0?sku=HS2018002")!
self.navigationController?.pushViewController(vc, animated: true)
window.webkit.messageHandlers.requestHybrid.postMessage({
name: "updateheader",
param: {
left: [{ tagname: "back", callback: "" }],
right: [],
title: { tagname: "title", title: "哈哈哈" }
}
});
Author
ucself ,lbj147123@163.com
License
JGHybrid is available under the MIT license. See the LICENSE file for more info.