Titanium.UI.iOS.WebViewPreferencesObject
The parameter passed to the Titanium.UI.iOS.WebViewConfiguration.preferences method.
Since: 8.0.0, 8.0.0, 9.2.0 · Platforms: iphone, ipad, macos
Properties #
javaScriptCanOpenWindowsAutomatically#
Type: Boolean
A Boolean value indicating whether JavaScript can open windows without user interaction.
javaScriptEnabled#
Type: Boolean
A Boolean value indicating whether JavaScript is enabled.
Setting this property to false disables JavaScripts that are loaded or executed by the web page.
This setting does not affect user scripts.
Examples #
Usage of WebViewConfiguration with WebView in iOS
Creates a configuration object and use it as property of webview.
var config = Ti.UI.iOS.createWebViewConfiguration({
allowsPictureInPictureMediaPlayback: true,
preferences: {
minimumFontSize : 20,
},
});
var webView = Ti.UI.createWebView({
configuration: config,
url: 'https://www.google.com'
});
var window = Ti.UI.createWindow();
window.add(webView);
window.open();