Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WebODF libs integration with WKWebView to open document files. #945

Open
VishalKumar2016 opened this issue Nov 2, 2017 · 0 comments
Open

Comments

@VishalKumar2016
Copy link

VishalKumar2016 commented Nov 2, 2017

WebODF libs integration with UIWebView: Integrated WebODF libs with UIWebView and it's working fine. Please find the below steps

  1. Load index.html file from WebODF libs on UIWebView
  2. Inject .odt file On webViewDidFinishLoad using below code snippet
_let jsFunction = "createEditor(\"../default.odt\", \"Test\", 375, 667)"
webView.stringByEvaluatingJavaScript(from: jsFunction)_
  1. Successfully load the odt file.

WebODF libs integration with WKWebView: Integrated WebODF libs with WKWebView but it's not working.

  1. Load index.html file from WebODF libs on WKWebView
  2. Inject .odt file On didFinish navigation using below code snippet
let jsFunction = "createEditor(\"../default.odt\", \"Test\", 375, 667)"
webView.evaluateJavaScript(jsFunction) { (result, error)
  1. Not able to load the file, only showing blank white screen. Even evaluateJavaScript function return true value.

Please let me know if anyone can find the solution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant