Package for working with WKWebView and for communicating between JS and Swift.
- Implement protocol
WebKitBridgeOutcomeEventwith functiongetScript(). Just return JS code in it as proper String. - Inside
WebKitBridgeViewControllercall methodrun(outcomeEvent:)and pass your protocol implementation
- Implement protocol
WebKitBridgeIncomeEvent. - When initalize
WebKitBridgeViewControllerpass realWebKitBridgeIncomeEventsManagerwith events (for exampleWebKitBridgeBaseIncomeEventsManager). - React on method
firein protocolWebKitBridgeIncomeEventimplementation.
designConfiguration- config for designlinkURL- url to openspinnerManagerType- type of entity, that will be initialized to display/hide spinnerincomeEventsManager- entity for creating and managing income eventsviewsProvider- entity for creating loading/reachability/error viewsreachabilityService- entity for providing info about reachability
Controller, that containt WKWebview.
domContentLoaded- called when dom contend loaded (likeviewDidAppear)
Manager for reloading all webviews.
