@@ -43,6 +43,10 @@ InAppBrowser window, by replacing window.open:
43
43
44
44
window.open = cordova.InAppBrowser.open;
45
45
46
+ If you change the browsers ` window.open ` function this way, it can have unintended side
47
+ effects (especially if this plugin is included only as a dependency of another
48
+ plugin).
49
+
46
50
The InAppBrowser window behaves like a standard web browser,
47
51
and can't access Cordova APIs. For this reason, the InAppBrowser is recommended
48
52
if you need to load third-party (untrusted) content, instead of loading that
@@ -52,22 +56,6 @@ whitelist, nor is opening links in the system browser.
52
56
The InAppBrowser provides by default its own GUI controls for the user (back,
53
57
forward, done).
54
58
55
- For backwards compatibility, this plugin also hooks ` window.open ` .
56
- However, the plugin-installed hook of ` window.open ` can have unintended side
57
- effects (especially if this plugin is included only as a dependency of another
58
- plugin). The hook of ` window.open ` will be removed in a future major release.
59
- Until the hook is removed from the plugin, apps can manually restore the default
60
- behaviour:
61
-
62
- delete window.open // Reverts the call back to its prototype's default
63
-
64
- Although ` window.open ` is in the global scope, InAppBrowser is not available until after the ` deviceready ` event.
65
-
66
- document.addEventListener("deviceready", onDeviceReady, false);
67
- function onDeviceReady() {
68
- console.log("window.open works well");
69
- }
70
-
71
59
## Installation
72
60
73
61
cordova plugin add cordova-plugin-inappbrowser
0 commit comments