Skip to content

Comment on WebGL on iOS8 Safari and WebView

Comments

Any changes in the lovely JavaScript/Objective-C bridging stuff on iOS8? Does it work with the new stuff WebKit? Is it any better documented or have more features?

MacOS since 10.3 has the handy WebScriptObject / JSContext stuff, which made it into iOS 7, but wasn't very well documented, and took some tricks to use. You have to fish a JSContext out of the WebView with [webView valueForKeyPath: @"documentView.webView.mainFrame.javaScriptContext"] ...

https://developer.apple.com/library/mac/documentation/Cocoa/...

http://blog.impathic.com/post/64171814244/true-javascript-ui...

http://asciiwwdc.com/2013/sessions/615

http://www.steamclock.com/blog/2013/05/apple-objective-c-jav...

http://stackoverflow.com/questions/2254372/calling-javascrip...

http://will.thimbleby.net/script/

Here is the header file, the best documentation available:

/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS7.0.sdk/System/Library/Frameworks/JavaScriptCore.framework/Headers/JSContext.h

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.