Author: steven
Date: Thu Aug  9 02:48:54 2018
New Revision: 1837686

URL: http://svn.apache.org/viewvc?rev=1837686&view=rev
Log:
Updated docs

Added:
    cordova/site/public/news/2018/08/
    cordova/site/public/news/2018/08/01/
    cordova/site/public/news/2018/08/01/future-cordova-ios-webview.html
    cordova/site/public/static/img/blog/2018/arch-webview-engine.png   (with 
props)
    cordova/site/public/static/img/blog/2018/bridge-webview-engine.png   (with 
props)
Modified:
    cordova/site/public/announcements/2018/07/26/cordova-ios-4.5.5.html
    cordova/site/public/blog/index.html
    cordova/site/public/feed.xml
    cordova/site/public/sitemap.xml
    cordova/site/public/static/css/main.css
    cordova/site/public/static/js/index.js

Modified: cordova/site/public/announcements/2018/07/26/cordova-ios-4.5.5.html
URL: 
http://svn.apache.org/viewvc/cordova/site/public/announcements/2018/07/26/cordova-ios-4.5.5.html?rev=1837686&r1=1837685&r2=1837686&view=diff
==============================================================================
--- cordova/site/public/announcements/2018/07/26/cordova-ios-4.5.5.html 
(original)
+++ cordova/site/public/announcements/2018/07/26/cordova-ios-4.5.5.html Thu Aug 
 9 02:48:54 2018
@@ -169,6 +169,26 @@ cordova platform add ios@latest
             </div>
             <div class="col-sm-6">
                 
+                    <a 
href="/news/2018/08/01/future-cordova-ios-webview.html">Next</a>
+                    <br>
+                    <br>
+                    <a class="title" 
href="/news/2018/08/01/future-cordova-ios-webview.html">Breaking changes coming 
to the iOS WebView in Apache Cordova</a>
+                    <div class="date"> 01 Aug 2018 - By Shazron Abdullah </div>
+                    <p class="content">
+                        <!--
+                            NOTE:
+                                the markdownify filter is used here
+                                because posts are rendered in sequence;
+                                that is, the next post's content isn't
+                                yet rendered at the time that this post
+                                is being rendered, so page.next.excerpt
+                                is still in Markdown and not HTML
+
+                            Reference: 
https://github.com/jekyll/jekyll/issues/2860
+                        -->
+                        With the announcement of the iOS 12 beta SDK at 
Apple’s WWDC...
+                    </p>
+                
             </div>
         </div>
     </footer>

Modified: cordova/site/public/blog/index.html
URL: 
http://svn.apache.org/viewvc/cordova/site/public/blog/index.html?rev=1837686&r1=1837685&r2=1837686&view=diff
==============================================================================
--- cordova/site/public/blog/index.html (original)
+++ cordova/site/public/blog/index.html Thu Aug  9 02:48:54 2018
@@ -124,6 +124,42 @@
             
             <li>
                 <header>
+                    <div class="adorner" blogTime="Wed, 01 Aug 2018 00:00:00 
+0000"></div>
+                    <h2 class="title">
+                        <a 
href="/news/2018/08/01/future-cordova-ios-webview.html">Breaking changes coming 
to the iOS WebView in Apache Cordova</a>
+                    </h2>
+                    <div class="details">
+                        <span class="date">01 Aug 2018</span>
+                        - by
+                        <span class="author">
+                            
+                                <a href="https://twitter.com/shazron";>Shazron 
Abdullah</a>
+                            
+                        </span>
+                        <a class="comment" 
href="/news/2018/08/01/future-cordova-ios-webview.html#disqus_thread"></a>
+                    </div>
+                </header>
+                <section class="post-excerpt">
+                    <p><p>With the announcement of the iOS 12 beta SDK at 
Apple’s WWDC 2018, came the news that UIWebView, the webview originally 
bundled with the first iOS SDK, has been <a 
href="https://developer.apple.com/documentation/uikit/uiwebview";>deprecated</a>.
 What this means for iOS developers is that sometime in the future, Apple will 
remove UIWebView from their SDK, and developers should migrate to using the 
WKWebView component starting right now.</p>
+
+<h2>WebView Engine Plugins</h2>
+
+<p>Cordova iOS, starting with version 4, has anticipated this by moving the 
webview that is used by the platform into a plugin. The default webview that is 
used is still UIWebView, but you had the option to use WKWebView instead, with 
the <a 
href="https://github.com/apache/cordova-plugin-wkwebview-engine";>cordova-plugin-wkwebview-engine</a>
 plugin. Both the UIWebView and WKWebView webviews are plugins themselves, with 
the former included in the cordova-ios platform.</p>
+
+<p><img src="/static/img/blog/2018/arch-webview-engine.png" alt="Figure 1"></p>
+
+<h2>Cordova iOS 5 with WKWebView</h2>
+
+<p>Starting with Cordova iOS version 5, which is a planned upcoming release, 
we will ship both webview plugins with the cordova-ios platform, to enable 
developers to test and transition users to the new WKWebView component. Cordova 
iOS 5 will ship with a bridge webview plugin that can switch usage of the 
webview plugin used at runtime. Previously, you could only choose which webview 
you would use at build time.</p>
+
+<p><img src="/static/img/blog/2018/bridge-webview-engine.png" alt="Figure 
2"></p>
+</p>
+                    <div><a 
href="/news/2018/08/01/future-cordova-ios-webview.html">More...</a></div>
+                </section>
+            </li>
+            
+            <li>
+                <header>
                     <div class="adorner" blogTime="Thu, 26 Jul 2018 00:00:00 
+0000"></div>
                     <h2 class="title">
                         <a 
href="/announcements/2018/07/26/cordova-ios-4.5.5.html">Cordova iOS 4.5.5 
Released!</a>
@@ -7594,7 +7630,7 @@ window.twttr = (function(d, s, id) {
 <script>
     window.onload = function(){
         setTimeout(function(){
-            var lastPostTime = new Date("Thu, 26 Jul 2018 00:00:00 
+0000").getTime();
+            var lastPostTime = new Date("Wed, 01 Aug 2018 00:00:00 
+0000").getTime();
           setCookie("visitTime", lastPostTime, 365);
         }, 2000);
     };

Modified: cordova/site/public/feed.xml
URL: 
http://svn.apache.org/viewvc/cordova/site/public/feed.xml?rev=1837686&r1=1837685&r2=1837686&view=diff
==============================================================================
--- cordova/site/public/feed.xml (original)
+++ cordova/site/public/feed.xml Thu Aug  9 02:48:54 2018
@@ -6,11 +6,110 @@
 </description>
     <link>https://cordova.apache.org/</link>
     <atom:link href="https://cordova.apache.org/feed.xml"; rel="self" 
type="application/rss+xml"/>
-    <pubDate>Wed, 08 Aug 2018 18:25:26 +0000</pubDate>
-    <lastBuildDate>Wed, 08 Aug 2018 18:25:26 +0000</lastBuildDate>
+    <pubDate>Thu, 09 Aug 2018 02:24:28 +0000</pubDate>
+    <lastBuildDate>Thu, 09 Aug 2018 02:24:28 +0000</lastBuildDate>
     <generator>Jekyll v2.5.3</generator>
     
       <item>
+        <title>Breaking changes coming to the iOS WebView in Apache 
Cordova</title>
+        <description>&lt;p&gt;With the announcement of the iOS 12 beta SDK at 
Apple’s WWDC 2018, came the news that UIWebView, the webview originally 
bundled with the first iOS SDK, has been &lt;a 
href=&quot;https://developer.apple.com/documentation/uikit/uiwebview&quot;&gt;deprecated&lt;/a&gt;.
 What this means for iOS developers is that sometime in the future, Apple will 
remove UIWebView from their SDK, and developers should migrate to using the 
WKWebView component starting right now.&lt;/p&gt;
+
+&lt;h2&gt;WebView Engine Plugins&lt;/h2&gt;
+
+&lt;p&gt;Cordova iOS, starting with version 4, has anticipated this by moving 
the webview that is used by the platform into a plugin. The default webview 
that is used is still UIWebView, but you had the option to use WKWebView 
instead, with the &lt;a 
href=&quot;https://github.com/apache/cordova-plugin-wkwebview-engine&quot;&gt;cordova-plugin-wkwebview-engine&lt;/a&gt;
 plugin. Both the UIWebView and WKWebView webviews are plugins themselves, with 
the former included in the cordova-ios platform.&lt;/p&gt;
+
+&lt;p&gt;&lt;img src=&quot;/static/img/blog/2018/arch-webview-engine.png&quot; 
alt=&quot;Figure 1&quot;&gt;&lt;/p&gt;
+
+&lt;h2&gt;Cordova iOS 5 with WKWebView&lt;/h2&gt;
+
+&lt;p&gt;Starting with Cordova iOS version 5, which is a planned upcoming 
release, we will ship both webview plugins with the cordova-ios platform, to 
enable developers to test and transition users to the new WKWebView component. 
Cordova iOS 5 will ship with a bridge webview plugin that can switch usage of 
the webview plugin used at runtime. Previously, you could only choose which 
webview you would use at build time.&lt;/p&gt;
+
+&lt;p&gt;&lt;img 
src=&quot;/static/img/blog/2018/bridge-webview-engine.png&quot; 
alt=&quot;Figure 2&quot;&gt;&lt;/p&gt;
+
+&lt;!--more--&gt;
+
+&lt;h2&gt;Migration and Transition using the Bridge WebView Plugin&lt;/h2&gt;
+
+&lt;p&gt;The developer can switch the webview used by setting a preference, 
that will be read at runtime when the app starts. Developers can transition 
users to the new WKWebView by user choice, in their app settings -- or randomly 
perhaps as an A/B test. This will give the developer and their users a chance 
to try out the new component, and they can back out and use UIWebView if there 
are any problems, without needing a new app release. This is intended to be 
used for testing and migration purposes only -- developers should aim to 
support only WKWebView functionality going forward.&lt;/p&gt;
+
+&lt;h2&gt;Cordova iOS Future Release, WKWebView only&lt;/h2&gt;
+
+&lt;p&gt;When UIWebView support has been removed in a future iOS SDK, we will 
aim to release a future Cordova iOS version, which will remove UIWebView 
support, and WKWebView will then be the default webview engine.&lt;/p&gt;
+
+&lt;table&gt;&lt;thead&gt;
+&lt;tr&gt;
+&lt;th&gt;Cordova iOS 4 &amp;gt;&amp;gt;&amp;gt;&lt;/th&gt;
+&lt;th&gt;Cordova iOS 5 &amp;gt;&amp;gt;&amp;gt;&lt;/th&gt;
+&lt;th&gt;Cordova iOS Future Release&lt;/th&gt;
+&lt;/tr&gt;
+&lt;/thead&gt;&lt;tbody&gt;
+&lt;tr&gt;
+&lt;td&gt;&lt;/td&gt;
+&lt;td&gt;UIWebView deprecated&lt;/td&gt;
+&lt;td&gt;UIWebView removed&lt;/td&gt;
+&lt;/tr&gt;
+&lt;tr&gt;
+&lt;td&gt;&lt;/td&gt;
+&lt;td&gt;WKWebView Engine Plugin Integrated Into Platform&lt;/td&gt;
+&lt;td&gt;WKWebView Engine Plugin only&lt;/td&gt;
+&lt;/tr&gt;
+&lt;tr&gt;
+&lt;td&gt;&lt;/td&gt;
+&lt;td&gt;Bridge WebView Plugin Added&lt;/td&gt;
+&lt;td&gt;Bridge WebView Plugin Removed&lt;/td&gt;
+&lt;/tr&gt;
+&lt;/tbody&gt;&lt;/table&gt;
+
+&lt;h2&gt;Limitations of WKWebView&lt;/h2&gt;
+
+&lt;p&gt;There are &lt;a 
href=&quot;https://mjtsai.com/blog/2018/06/20/webview-and-uiwebview-deprecated-in-favor-of-wkwebview/&quot;&gt;many
 limitations&lt;/a&gt; of WKWebview, especially if you were using UIWebView 
previously. The limitations are:&lt;/p&gt;
+
+&lt;ol&gt;
+&lt;li&gt;Cookies don&amp;#39;t persist. This is a WebKit bug, but someone has
+created a plugin for a workaround. See
+&lt;a 
href=&quot;https://issues.apache.org/jira/browse/CB-12074&quot;&gt;CB-12074&lt;/a&gt;&lt;/li&gt;
+&lt;li&gt;Can&amp;#39;t delete cookies. This is/was a WebKit bug (2015), we 
need to test
+for the iOS 11/12. See &lt;a 
href=&quot;https://issues.apache.org/jira/browse/CB-11297&quot;&gt;CB-11297&lt;/a&gt;&lt;/li&gt;
+&lt;li&gt;Can&amp;#39;t execute JavaScript code in the background. There are 
several
+issues related to this. See
+&lt;a 
href=&quot;https://issues.apache.org/jira/browse/CB-12815&quot;&gt;CB-12815&lt;/a&gt;&lt;/li&gt;
+&lt;li&gt;XmlHttpRequests don&amp;#39;t work, because of Cross-Origin Resource
+Sharing issue (CORS). There is a workaround plugin created by Oracle
+(UPL licensed, which is Apache-2.0 compatible). See
+&lt;a 
href=&quot;https://issues.apache.org/jira/browse/CB-10143&quot;&gt;CB-10143&lt;/a&gt;&lt;/li&gt;
+&lt;li&gt;Migration of localStorage from UIWebView. There is a migration
+plugin available. See &lt;a 
href=&quot;https://issues.apache.org/jira/browse/CB-11974&quot;&gt;CB-11974&lt;/a&gt;&lt;/li&gt;
+&lt;li&gt;iframes will not be supported any longer (they are now CORS 
restricted in WKWebView), and may be partially or completely broken. This may 
lead to incompatibilities with the same code in other Cordova 
platforms.&lt;/li&gt;
+&lt;li&gt;Known issues with WKWebView on iOS pre-11 which will be deprecated 
and dropped in a future Cordova release&lt;/li&gt;
+&lt;/ol&gt;
+
+&lt;p&gt;There are several bugs that need to be resolved as well. The full list
+here: &lt;a 
href=&quot;https://s.apache.org/QfsF&quot;&gt;https://s.apache.org/QfsF&lt;/a&gt;&lt;/p&gt;
+
+&lt;p&gt;As you can see, WKWebView is not a direct drop-in replacement for 
UIWebView, you will need several plugins to patch functionality that is 
missing. There is also the &lt;a 
href=&quot;https://github.com/apache/cordova-plugins/tree/wkwebview-engine-localhost&quot;&gt;local-webserver
 experimental plugin option&lt;/a&gt;, which will not be graduated to a full 
plugin -- we will concentrate our efforts on supporting the main WKWebView 
engine plugin. &lt;/p&gt;
+
+&lt;p&gt;Hopefully with more testing, and filing of bug reports with Apple for 
missing features, the WKWebView can be a full replacement for Cordova 
users.&lt;/p&gt;
+</description>
+        <pubDate>Wed, 01 Aug 2018 00:00:00 +0000</pubDate>
+        
<link>https://cordova.apache.org/news/2018/08/01/future-cordova-ios-webview.html</link>
+        <guid 
isPermaLink="true">https://cordova.apache.org/news/2018/08/01/future-cordova-ios-webview.html</guid>
+        
+        <category>cordova-ios</category>
+        
+        <category>uiwebview</category>
+        
+        <category>wkwebview</category>
+        
+        <category>webview</category>
+        
+        <category>roadmap</category>
+        
+        
+        <category>news</category>
+        
+      </item>
+    
+      <item>
         <title>Cordova iOS 4.5.5 Released!</title>
         <description>&lt;p&gt;We are happy to announce that 
&lt;code&gt;Cordova iOS 4.5.5&lt;/code&gt; has been released! This release 
fixes various bugs releated to the previous 
&lt;code&gt;cordova-ios@4.5.4&lt;/code&gt; release.&lt;/p&gt;
 
@@ -460,308 +559,5 @@ cordova platform add android@7.1.0
         
       </item>
     
-      <item>
-        <title>A Better Way to Exercise Cordova Plugins</title>
-        <description>&lt;p&gt;Cordova developers have several ways to test and 
debug their Cordova applications. For functional testing, developers use 
emulators, simulators, and physical devices. Devices can be on-premises, or 
there are many cloud offerings available as well. There&amp;#39;s even great 
tools you can use to debug your applications such as the web app debugging 
capabilities of Chrome and Safari, as well as the excellent debugging 
capabilities of Microsoft&amp;#39;s Visual Studio Code extension for Apache 
Cordova.&lt;/p&gt;
-
-&lt;p&gt;For debugging plugins, or debugging applications that utilize Cordova 
plugins, things aren&amp;#39;t that bad. For most plugins, I imagine that any 
physical device has whatever&amp;#39;s needed to work with a plugin, unless the 
plugin requires some external hardware device or has other requirements that 
aren&amp;#39;t by every device. For several of the core Cordova plugins, the 
device emulators and simulators expose capabilities that enable testers to 
simulate things like the camera, accelerometer, compass, and other device-side 
capabilities (although, surprisingly, early iOS simulators didn&amp;#39;t 
support camera simulation).&lt;/p&gt;
-
-&lt;p&gt;When it comes to exercising all the capabilities of a plugin, 
especially simulating error conditions so you can tell how the app responds, it 
gets complicated. Developers often find themselves hacking away at plugin code, 
either mocking up simulation scenarios, or manually changing the behavior of 
the plugin during testing. In many cases, developers must manually force error 
conditions in their plugins so they can validate error checking within their 
app. I haven&amp;#39;t written many Cordova plugins, but in the little work I 
have done, I&amp;#39;ve wished that there was a better way. Well, it turns out 
that there is.&lt;/p&gt;
-
-&lt;!--more--&gt;
-
-&lt;p&gt;Many, many years ago, a small company named Tiny Hippos created the 
Ripple Emulator, a browser-based emulator for many mobile devices. Ripple was 
interesting in many ways, but for the scope of this article, one of the 
interesting features was its implementation of emulators for many of the core 
Cordova plugins. As you ran your Cordova application in one pane, a separate 
pane opened with options to control many aspects of the simulated environment 
as shown in the following figure.&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&quot;/static/img/blog/2018/cordova-simulate-1.png&quot; 
alt=&quot;Figure 1&quot;&gt;&lt;/p&gt;
-
-&lt;p&gt;Well, shortening a long story a bit, the folks at Research In Motion 
(BlackBerry) purchased Tiny Hippos and maintained Ripple for a while before 
finally contributing it to the Apache Foundation as an incubator project. Many 
companies got involved, including Adobe, Microsoft, and others, but the project 
never really took off, or ever became a stable product. It never actually made 
it out of beta.&lt;/p&gt;
-
-&lt;p&gt;Anyway, fast forward to today and you&amp;#39;ll find that Microsoft 
took the Ripple project and rebuilt it. We kept some of the original code (some 
of the plugin simulation panels and supporting utility functions), rewrote some 
parts, created some new code, then released it as an open source project called 
Cordova Simulate (&lt;a 
href=&quot;https://github.com/Microsoft/cordova-simulate&quot;&gt;https://github.com/Microsoft/cordova-simulate&lt;/a&gt;).
 We chose this approach, rather than investing in Ripple, because:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;We had regular reports of issues with Ripple starting and Visual 
Studio not being able to connect to it successfully, so we wanted a simpler 
architecture for rendering the Cordova web app (a separate browser window that 
just hosted the app, and nothing else).&lt;/li&gt;
-&lt;li&gt;Debugging Ripple was a challenge since you were effectively 
debugging both the app and Ripple itself (you had to drill down into the Ripple 
UI&amp;#39;s HTML to find the hosted Cordova web app, and Ripple&amp;#39;s 
JavaScript code could easily be a part of your stack when debugging).&lt;/li&gt;
-&lt;li&gt;Since Ripple and the Cordova web app render in the same browser 
window, if the Cordova web app froze for any reason, Ripple also froze (or, in 
less severe cases, the Ripple UI could look unresponsive when the Cordova web 
app is busy).&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;Cordova Simulate solves these issues:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;The app window doesn&amp;#39;t also host the simulation UI - just 
the app (and a small bit of code to enable communication with the simulation 
UI). This solves the first two problems identified above.&lt;/li&gt;
-&lt;li&gt;The simulation UI renders in a separate window, and all 
communication is asynchronous, so an unresponsive app won&amp;#39;t interfere 
with the simulation UI. This solves the third problem.&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;Another driving purpose for Cordova Simulate was that we wanted to 
make it extensible; allowing plugins to define their own simulation 
functionality (as you&amp;#39;ll soon learn about).&lt;/p&gt;
-
-&lt;p&gt;To my previous point about Ripple never making it out of beta, not 
only is Cordova Simulate a complete, robust, and released solution, 
it&amp;#39;s even part of several Microsoft offerings (both commercial and open 
source). Its bundled into Visual Studio Tools for Apache Cordova (TACO - &lt;a 
href=&quot;http://taco.visualstudio.com/&quot;&gt;http://taco.visualstudio.com/&lt;/a&gt;)
 in Visual Studio 2017. It&amp;#39;s also included as part of the Apache 
Cordova extension for Visual Studio Code (&lt;a 
href=&quot;https://github.com/Microsoft/vscode-cordova&quot;&gt;https://github.com/Microsoft/vscode-cordova&lt;/a&gt;).
 &lt;/p&gt;
-
-&lt;p&gt;Why is this important to you? Well, let me explain...&lt;/p&gt;
-
-&lt;p&gt;With Cordova Simulate, you now have access to a complete solution for 
testing your apps against simulated versions of the core Cordova plugins. This 
eliminates the need to hack up your code to simulate plugin responses as 
Cordova Simulate takes care of that for you.&lt;/p&gt;
-
-&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; If you just read the last 
paragraph, and said to yourself &amp;quot;so what?&amp;quot; just hang on for a 
little while longer.&lt;/p&gt;
-
-&lt;p&gt;The most important benefit for you is that you can add support for 
Cordova Simulate to each of your custom plugins as well. Then, when 
you&amp;#39;re exercising your plugins during plugin development, or when your 
customers are using your plugins, you have a standard way to simulate the 
capabilities of your plugin (including error scenarios). When third-party 
providers add support for Cordova Simulate to their plugins, suddenly 
developers can accurately test each aspect of their application using a variety 
of plugins.&lt;/p&gt;
-
-&lt;p&gt;Let me show you how to install and use Cordova Simulate, then 
I&amp;#39;ll show you how to add support for Cordova Simulate to your custom 
plugins. If you&amp;#39;re using someone else&amp;#39;s plugin, and they 
don&amp;#39;t have support for Cordova Simulate in the plugin, add it yourself 
and submit a pull request, it&amp;#39;s not that hard.&lt;/p&gt;
-
-&lt;h2&gt;Installing Cordova Simulate&lt;/h2&gt;
-
-&lt;p&gt;As I mentioned before, Visual Studio Tools for Apache Cordova and the 
Cordova extension for Visual Studio Code both include Cordova Simulate, so 
there&amp;#39;s no extra installation instructions to follow - just install the 
tools, and you&amp;#39;ll have what you need.&lt;/p&gt;
-
-&lt;p&gt;You can also invoke Cordova Simulate from the command line, or from 
third party IDEs. To install Cordova Simulate for those scenarios, open a 
terminal window, and execute the following command:&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;npm install -g 
cordova-simulate
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;That&amp;#39;s it, that&amp;#39;s all there is to it. When the 
process completes, you&amp;#39;ll now have a &lt;code&gt;simulate&lt;/code&gt; 
command at your disposal to launch Cordova Simulate.&lt;/p&gt;
-
-&lt;h2&gt;Launching Cordova Simulate&lt;/h2&gt;
-
-&lt;p&gt;The following sections describe how to launch Cordova Simulate in 
different ways.&lt;/p&gt;
-
-&lt;h3&gt;Visual Studio&lt;/h3&gt;
-
-&lt;p&gt;If you&amp;#39;re running an app in Visual Studio &amp;amp; TACO, 
just choose the &lt;strong&gt;Simulate in Browser&lt;/strong&gt; option, and 
the app launches Cordova Simulate. Cordova Simulate will open the Chrome 
browser and run the web application part of your Cordova app. Cordova Simulate 
will also open a simulator control window in Visual Studio (using Internet 
Explorer, no surprise there). You&amp;#39;ll interact with the app in the 
Chrome window and simulate methods and properties in the plugins using the 
simulator control window. I&amp;#39;ll show you how in a minute.&lt;/p&gt;
-
-&lt;h3&gt;Visual Studio Code&lt;/h3&gt;
-
-&lt;p&gt;If you&amp;#39;re using Visual Studio Code, go to the 
&lt;strong&gt;Debug&lt;/strong&gt; tab, enable &lt;strong&gt;Cordova 
debugging&lt;/strong&gt;, then execute either the &lt;strong&gt;Simulate 
Android in browser&lt;/strong&gt; or &lt;strong&gt;Simulate iOS in 
browser&lt;/strong&gt; options. Cordova Simulate will open the Chrome browser 
and execute the web application part of your Cordova app. Cordova Simulate will 
also open a simulator control window inside Visual Studio Code. You&amp;#39;ll 
interact with the app in the Chrome window and simulate methods and properties 
in the plugins using the simulator control window. I&amp;#39;ll show you how in 
a minute.&lt;/p&gt;
-
-&lt;h3&gt;Command-line&lt;/h3&gt;
-
-&lt;p&gt;To launch Cordova Simulate from the command-line, open a terminal 
window, navigate to a Cordova project folder, and execute the following 
command:&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;simulate \[platform\]
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;Platform refers to one of the supported target platforms (for 
example: &lt;code&gt;android&lt;/code&gt;, &lt;code&gt;ios&lt;/code&gt;, or 
&lt;code&gt;browser&lt;/code&gt;). For example, to simulate the Android version 
of your Cordova application, you would use the following:&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;simulate android
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;Cordova Simulate will open the Chrome browser with two tabs, one 
running the Cordova app web app, and the other displaying the simulator control 
window shown in the following figure.&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&quot;/static/img/blog/2018/cordova-simulate-2.png&quot; 
alt=&quot;Figure 2&quot;&gt;&lt;/p&gt;
-
-&lt;p&gt;By default, Cordova Simulate loads a default set of plugin 
simulators:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;Since HTML has native support for geolocation, Cordova Simulate 
automatically loads the Geolocation simulator pane.&lt;/li&gt;
-&lt;li&gt;The event simulator pane loads automatically to enable developers to 
trigger Cordova and device events as needed&lt;/li&gt;
-&lt;li&gt;Persisted Exec Calls pane enables basic simulator support for 
third-party plugins that don&amp;#39;t include support for Cordova 
Simulate.&lt;/li&gt;
-&lt;li&gt;The Device simulator loads automatically to enable you to change the 
target device used for rendering the web app.&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;If I&amp;#39;d added other Cordova core plugins to my project, 
Cordova Simulate would load simulators for each, if available.&lt;/p&gt;
-
-&lt;p&gt;At this point, you can interact with your app as needed, and switch 
to the simulator control window to adjust plugin properties and method call 
results. For example, if your Cordova app used the Geolocation plugin to track 
the device&amp;#39;s location, changing any of the values in the Geolocation 
simulator pane would cause the app&amp;#39;s next call to 
&lt;code&gt;navigator.geolocation.getCurrentPosition&lt;/code&gt; to receive 
the updated value you entered into the pane.&lt;/p&gt;
-
-&lt;h2&gt;Adding Cordova Simulate Support to Your Plugins&lt;/h2&gt;
-
-&lt;p&gt;Alright, it&amp;#39;s time to show you how to add Cordova Simulate 
support to your own plugins. First, you must add a 
&lt;code&gt;simulation&lt;/code&gt; folder to your plugin&amp;#39;s 
&lt;code&gt;src&lt;/code&gt; folder (so 
&lt;code&gt;src/simulation/&lt;/code&gt;). Inside that folder, you&amp;#39;ll 
create one or more of the following files based on the needs of your 
plugin:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;&lt;code&gt;app-host-clobbers.js&lt;/code&gt;&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;app-host-handlers.js&lt;/code&gt;&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;app-host.js&lt;/code&gt;&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;sim-host-dialogs.html&lt;/code&gt;&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;sim-host-handlers.js&lt;/code&gt;&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;sim-host-panels.html&lt;/code&gt;&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;sim-host.js&lt;/code&gt;&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;For my simple example, I&amp;#39;m only going to need three files, 
but refer to the Cordova Simulate documentation at &lt;a 
href=&quot;https://github.com/Microsoft/cordova-simulate&quot;&gt;https://github.com/Microsoft/cordova-simulate&lt;/a&gt;
 for details about each of these files.&lt;/p&gt;
-
-&lt;p&gt;The plugin I used for my example is a simple Carrier plugin I created 
many years ago for one of my Cordova books: &lt;a 
href=&quot;https://www.npmjs.com/package/johnwargo-cordova-plugin-carrier&quot;&gt;https://www.npmjs.com/package/johnwargo-cordova-plugin-carrier&lt;/a&gt;.
 It exposes two methods:&lt;/p&gt;
-
-&lt;ul&gt;
-&lt;li&gt;&lt;code&gt;getCarrierName&lt;/code&gt;: An asynchronous method that 
retrieves the current carrier for the device running the application.&lt;/li&gt;
-&lt;li&gt;&lt;code&gt;getCountryCode&lt;/code&gt;: An asynchronous method that 
retrieves the country code for the device running the application&lt;/li&gt;
-&lt;/ul&gt;
-
-&lt;p&gt;When exercising this plugin, I&amp;#39;ll need the ability to 
validate my app&amp;#39;s code against different carrier and country code 
values. To simulate this, I&amp;#39;ll need an HTML panel that offers multiple 
carrier and country code choices. For this, I created a 
&lt;code&gt;sim-host.panels.html&lt;/code&gt; file in the plugin 
project&amp;#39;s &lt;code&gt;src/simulation/&lt;/code&gt; folder. The file 
creates a simple panel with two drop-down lists containing some country and 
carrier values:&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;&amp;lt;cordova-panel 
id=&quot;johnwargo-cordova-plugin-carrier&quot; caption=&quot;Carrier&quot; 
-  spoken-text=&quot;Carrier&quot;&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-        Select carrier and country code options from the drop-down lists below.
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-        &amp;lt;cordova-label label=&quot;Carrier Name&quot; 
spoken=&quot;carrier name&quot;&amp;gt;&amp;lt;/cordova-label&amp;gt;
-        &amp;lt;cordova-combo spoken-text=&quot;Simulated value for wireless 
carrier&quot; 
-           id=&quot;carrier-select&quot; style=&quot;width:auto; min-width:0; 
display:inline;&quot;&amp;gt;
-            &amp;lt;option value=&quot;AT&amp;amp;T&quot; 
selected=&quot;selected&quot;&amp;gt;AT&amp;amp;T&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;Sprint&quot;&amp;gt;Sprint&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;T-Mobile&quot;&amp;gt;T-Mobile&amp;lt;/option&amp;gt;
-            &amp;lt;option value=&quot;US Cellular&quot;&amp;gt;US 
Cellular&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;Verizon&quot;&amp;gt;Verizon&amp;lt;/option&amp;gt;
-        &amp;lt;/cordova-combo&amp;gt;
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-        &amp;lt;cordova-label label=&quot;Country Code&quot; 
spoken=&quot;country code&quot;&amp;gt;&amp;lt;/cordova-label&amp;gt;
-        &amp;lt;cordova-combo spoken-text=&quot;Simulated value for country 
code&quot; 
-          id=&quot;country-code-select&quot; style=&quot;width:auto; 
min-width:0; display:inline;&quot;&amp;gt;
-            &amp;lt;option 
value=&quot;CA&quot;&amp;gt;Canada&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;MX&quot;&amp;gt;Mexico&amp;lt;/option&amp;gt;
-            &amp;lt;option value=&quot;US&quot; 
selected=&quot;selected&quot;&amp;gt;United States&amp;lt;/option&amp;gt;
-        &amp;lt;/cordova-combo&amp;gt;
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-      Enable the error checkbox to execute the error callback instead of the 
success callback on plugin API calls.
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-checkbox id=&quot;is-error&quot; 
spoken=&quot;&quot;&amp;gt;Error condition&amp;lt;/cordova-checkbox&amp;gt;
-&amp;lt;/cordova-panel&amp;gt;
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;As you can see from the code, the panel makes use of special HTML 
element types supported by Cordova Simulate. The simulator code for most of the 
core Cordova plugins is included with the Cordova Simulate Github repository, 
so you can find examples there of the available UI elements in use.&lt;/p&gt;
-
-&lt;p&gt;Next, I added a &lt;code&gt;sim-host.js&lt;/code&gt; file to the 
folder. This file isn&amp;#39;t necessary, but it provides an opportunity to 
initialize the simulated plugin, and I use it to update the console whenever 
the user makes a change in the simulation panel. Not critically important, but 
useful as I sorted out what was happening as I built the simulation.&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;module.exports = {
-    initialize: function() {
-        //Get access to the carrier selection drop-down
-        var carrierSel = document.getElementById(&#39;carrier-select&#39;);
-        //Add a change event listener to the field
-        carrierSel.addEventListener(&#39;change&#39;, carrierChange);
-        //Get access to the country code selection drop-down
-        var ccSel = document.getElementById(&#39;country-code-select&#39;);
-        //Add a change event listener to the field
-        ccSel.addEventListener(&#39;change&#39;, ccChange); 
-
-        function carrierChange() {
-            console.log(&quot;Carrier selection changed to &quot; + 
this.value);
-        }
-
-        function ccChange() {
-            console.log(&quot;Country code selection changed to &quot; + 
this.value);
-        }
-    }
-};
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;If you study the source code for the simulator capabilities in the 
core Cordova plugins, you&amp;#39;ll see that many of them use change events 
like the ones just shown in the code to update properties for objects exposed 
by the plugins. As developers change values in the simulator panel, the change 
events register the change and updates a local object. Then, when a Cordova 
application accesses one of those properties, the code returns the value from 
the local object.&lt;/p&gt;
-
-&lt;p&gt;Finally, I added a &lt;code&gt;sim-host-handlers.js&lt;/code&gt; file 
to the project. The code in this file overrides the 
&lt;code&gt;cordova.exec&lt;/code&gt; calls from the plugin in the simulated 
environment. Here, I export the native methods supported by the plugin and pull 
the selected values from the simulator panel and return them to the calling 
application.&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;module.exports = 
function(messages) {
-    return {
-        carrier: {
-            getCarrierName: function(successCallback, errorCallback) {
-                console.log(&quot;Cordova-Simulate: getCarrierName 
invoked&quot;);
-                //Get access to the carrier selection drop-down
-                var carrierSel = 
document.getElementById(&#39;carrier-select&#39;);
-                //Pull the value from the selected item
-                var selValue = 
carrierSel.options[carrierSel.selectedIndex].value;
-                console.log(&#39;Simulating carrier: &#39; + selValue);
-                //And return it to the calling method
-                successCallback(selValue);
-            },
-            getCountryCode: function(successCallback, errorCallback) {
-                console.log(&quot;Cordova-Simulate: getCountryCode 
invoked&quot;);
-                //Get access to the country code selection drop-down
-                var ccSel = 
document.getElementById(&#39;country-code-select&#39;);
-                //Pull the value from the selected item
-                var selValue = ccSel.options[ccSel.selectedIndex].value;
-                console.log(&#39;Simulating country code: &#39; + selValue);
-                //And return it to the calling method
-                successCallback(selValue);
-            }
-        }
-    };
-};
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;This is a very simple example of what you can do, be sure to check 
out the source code for the simulator capabilities included with core Cordova 
plugins for more sophisticated examples.&lt;/p&gt;
-
-&lt;p&gt;Now, when you create a Cordova application that uses this plugin, 
then execute Cordova Simulate, you&amp;#39;ll see the following panel exposed 
on the Cordova Simulate Simulator Control window:&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&quot;/static/img/blog/2018/cordova-simulate-3.png&quot; 
alt=&quot;Figure 3&quot;&gt;&lt;/p&gt;
-
-&lt;p&gt;Make the appropriate changes to the panel, then call the associated 
APIs from the Cordova application to see the selected results.&lt;/p&gt;
-
-&lt;p&gt;If you think about what we&amp;#39;ve done so far, we&amp;#39;ve only 
addressed success scenarios - changing the behavior of the plugin in the 
simulated environment so we can test the app with different API results. Most 
plugins also report error conditions, and in order to properly exercise the 
plugin or an app using the plugin, you must be able to simulate error 
conditions as well. Let me show you how to do that.&lt;/p&gt;
-
-&lt;p&gt;First, I added a new row to the 
&lt;code&gt;sim-host.panels.html&lt;/code&gt; file:&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; 
data-lang=&quot;&quot;&gt;&amp;lt;cordova-panel-row&amp;gt;
-  Enable the error checkbox to execute the error callback instead of the 
success callback on plugin API calls.
-&amp;lt;/cordova-panel-row&amp;gt;
-&amp;lt;cordova-checkbox id=&quot;is-error&quot; 
spoken=&quot;&quot;&amp;gt;Error condition&amp;lt;/cordova-checkbox&amp;gt;
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;This adds an Error checkbox to the panel, enabling developers to 
return an error from each plugin API call. The updated 
&lt;code&gt;sim-host.panels.html&lt;/code&gt; file looks like this:&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;&amp;lt;cordova-panel 
id=&quot;johnwargo-cordova-plugin-carrier&quot; caption=&quot;Carrier&quot; 
-  spoken-text=&quot;Carrier&quot;&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-        Select carrier and country code options from the drop-down lists below.
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-        &amp;lt;cordova-label label=&quot;Carrier Name&quot; 
spoken=&quot;carrier name&quot;&amp;gt;&amp;lt;/cordova-label&amp;gt;
-        &amp;lt;cordova-combo spoken-text=&quot;Simulated value for wireless 
carrier&quot; 
-           id=&quot;carrier-select&quot; style=&quot;width:auto; min-width:0; 
display:inline;&quot;&amp;gt;
-            &amp;lt;option value=&quot;AT&amp;amp;T&quot; 
selected=&quot;selected&quot;&amp;gt;AT&amp;amp;T&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;Sprint&quot;&amp;gt;Sprint&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;T-Mobile&quot;&amp;gt;T-Mobile&amp;lt;/option&amp;gt;
-            &amp;lt;option value=&quot;US Cellular&quot;&amp;gt;US 
Cellular&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;Verizon&quot;&amp;gt;Verizon&amp;lt;/option&amp;gt;
-        &amp;lt;/cordova-combo&amp;gt;
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-        &amp;lt;cordova-label label=&quot;Country Code&quot; 
spoken=&quot;country code&quot;&amp;gt;&amp;lt;/cordova-label&amp;gt;
-        &amp;lt;cordova-combo spoken-text=&quot;Simulated value for country 
code&quot; 
-          id=&quot;country-code-select&quot; style=&quot;width:auto; 
min-width:0; display:inline;&quot;&amp;gt;
-            &amp;lt;option 
value=&quot;CA&quot;&amp;gt;Canada&amp;lt;/option&amp;gt;
-            &amp;lt;option 
value=&quot;MX&quot;&amp;gt;Mexico&amp;lt;/option&amp;gt;
-            &amp;lt;option value=&quot;US&quot; 
selected=&quot;selected&quot;&amp;gt;United States&amp;lt;/option&amp;gt;
-        &amp;lt;/cordova-combo&amp;gt;
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-panel-row&amp;gt;
-      Enable the error checkbox to execute the error callback instead of the 
success callback on plugin API calls.
-    &amp;lt;/cordova-panel-row&amp;gt;
-    &amp;lt;cordova-checkbox id=&quot;is-error&quot; 
spoken=&quot;&quot;&amp;gt;Error condition&amp;lt;/cordova-checkbox&amp;gt;
-&amp;lt;/cordova-panel&amp;gt;
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;Now, in the &lt;code&gt;sim-host-handlers.js&lt;/code&gt; file, I 
added a check for the checkbox status in each of the methods exposed in the 
file. For my plugin, with the checkbox checked, the method calls the error 
callback function returning a dummy JSON object containing a simple error 
message and code. For your plugins, you&amp;#39;ll likely want to expand this 
so you can simulate different error conditions.&lt;/p&gt;
-&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code 
class=&quot;language-&quot; data-lang=&quot;&quot;&gt;module.exports = 
function(messages) {
-    return {
-        carrier: {
-            getCarrierName: function(successCallback, errorCallback) {
-                console.log(&quot;Cordova-Simulate: getCarrierName 
invoked&quot;);
-                if (document.getElementById(&#39;is-error&#39;).checked) {
-                    console.error(&quot;Error condition enabled&quot;);
-                    errorCallback({ code: 1, msg: &quot;Simulated error 
condition&quot; });
-                } else {
-                    //Get access to the carrier selection drop-down
-                    var carrierSel = 
document.getElementById(&#39;carrier-select&#39;);
-                    //Pull the value from the selected item
-                    var selValue = 
carrierSel.options[carrierSel.selectedIndex].value;
-                    console.log(&#39;Simulating carrier: &#39; + selValue);
-                    //And return it to the calling method
-                    successCallback(selValue);
-                }
-            },
-            getCountryCode: function(successCallback, errorCallback) {
-                if (document.getElementById(&#39;is-error&#39;).checked) {
-                    console.error(&quot;Error condition enabled&quot;);
-                    errorCallback({ code: 2, msg: &quot;Simulated error 
condition&quot; });
-                } else {
-                    console.log(&quot;Cordova-Simulate: getCountryCode 
invoked&quot;);
-                    //Get access to the country code selection drop-down
-                    var ccSel = 
document.getElementById(&#39;country-code-select&#39;);
-                    //Pull the value from the selected item
-                    var selValue = ccSel.options[ccSel.selectedIndex].value;
-                    console.log(&#39;Simulating country code: &#39; + 
selValue);
-                    //And return it to the calling method
-                    successCallback(selValue);
-                }
-            }
-        }
-    };
-};
-&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;
-&lt;p&gt;Now, when I execute Cordova simulate I&amp;#39;ll see the slightly 
different panel shown below.&lt;/p&gt;
-
-&lt;p&gt;&lt;img src=&quot;/static/img/blog/2018/cordova-simulate-4.png&quot; 
alt=&quot;Figure 4&quot;&gt;&lt;/p&gt;
-
-&lt;p&gt;That&amp;#39;s it, that&amp;#39;s all there is to enable simulation 
in your own plugins. As you can hopefully see, Cordova Simulate gives 
developers (plugin developers and developers who use those developer&amp;#39;s 
plugins in their applications) an easier way to exercise the plugin and test 
applications using the plugin. &lt;/p&gt;
-
-&lt;p&gt;Cordova Simulate is an open source project from Microsoft, but 
we&amp;#39;d love to have your help enhancing it and fixing issues as they 
arise. Please follow the project on Github and take a look at how you can help 
enhance this project.&lt;/p&gt;
-</description>
-        <pubDate>Fri, 02 Feb 2018 00:00:00 +0000</pubDate>
-        
<link>https://cordova.apache.org/howto/2018/02/02/cordova-simulate.html</link>
-        <guid 
isPermaLink="true">https://cordova.apache.org/howto/2018/02/02/cordova-simulate.html</guid>
-        
-        
-        <category>howto</category>
-        
-      </item>
-    
   </channel>
 </rss>

Added: cordova/site/public/news/2018/08/01/future-cordova-ios-webview.html
URL: 
http://svn.apache.org/viewvc/cordova/site/public/news/2018/08/01/future-cordova-ios-webview.html?rev=1837686&view=auto
==============================================================================
--- cordova/site/public/news/2018/08/01/future-cordova-ios-webview.html (added)
+++ cordova/site/public/news/2018/08/01/future-cordova-ios-webview.html Thu Aug 
 9 02:48:54 2018
@@ -0,0 +1,351 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+    <meta charset="utf-8">
+    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
+    <meta name="format-detection" content="telephone=no">
+    <meta name="viewport" content="user-scalable=no, initial-scale=1, 
maximum-scale=1, minimum-scale=1, width=device-width" />
+    <meta name="description" content="With the announcement of the iOS 12 beta 
SDK at Apple’s WWDC 2018, came the news that UIWebView, the webview 
originally bundled with the first iOS SDK, has b...">
+
+    <title>
+        
+            
+                Breaking changes coming to the iOS WebView in Apache Cordova - 
Apache Cordova
+            
+        
+    </title>
+
+    <link rel="SHORTCUT ICON" href="/favicon.ico"/>
+
+    
+
+    
+    
+
+    <link rel="canonical" 
href="https://cordova.apache.org/news/2018/08/01/future-cordova-ios-webview.html";>
+
+    <!-- CSS -->
+    <link rel="stylesheet" type="text/css" href="/static/css/main.css">
+    <link rel="stylesheet" type="text/css" href="/static/css/lib/syntax.css">
+    <!-- Algolia Search CSS -->
+    <link rel="stylesheet" 
href="https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.css"; />
+
+    <!-- Fonts -->
+    <!-- For attribution information, see www/attributions.html -->
+    <link 
href='https://fonts.googleapis.com/css?family=Raleway:700,400,300,700italic,400italic,300italic'
 rel='stylesheet' type='text/css'>
+
+    <!-- HTML5 shim and Respond.js for IE8 support of HTML5 elements and media 
queries -->
+    <!--[if lt IE 9]>
+        <script 
src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js";></script>
+        <script 
src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js";></script>
+    <![endif]-->
+    <script type="text/javascript">
+        var disqus_developer = 1; // this would set it to developer mode
+    </script>
+
+    <!-- JS -->
+    <script defer type="text/javascript" 
src="/static/js/lib/jquery-2.1.1.min.js"></script>
+    <script defer type="text/javascript" 
src="/static/js/lib/bootstrap.min.js"></script>
+    <script defer type="text/javascript" 
src="/static/js/lib/ZeroClipboard.js"></script>
+
+    <script>
+    
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
+    (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new 
Date();a=s.createElement(o),
+    
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
+    
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
+    ga('create', 'UA-64283057-3', 'auto');
+    ga('send', 'pageview');
+</script>
+
+</head>
+
+<body>
+    <header>
+    <a class="scroll-point pt-top" name="top"></a>
+    <nav class="navbar navbar-inverse navbar-fixed-top">
+        <div class="container-fluid">
+            <div class="navbar-header">
+                <button type="button" class="navbar-toggle collapsed" 
data-toggle="collapse" data-target="#navbar" aria-expanded="false" 
aria-controls="navbar">
+                    <span class="sr-only">Toggle navigation</span>
+                    <span class="icon-bar"></span>
+                    <span class="icon-bar"></span>
+                    <span class="icon-bar"></span>
+                </button>
+                <a class="navbar-brand" href="/"><img id="logo_top" 
src="/static/img/cordova-logo-newbrand.svg"/></a>
+            </div>
+            <div id="navbar" class="navbar-collapse collapse">
+                <div class="nav_bar_center">
+                    <ul class="nav navbar-nav">
+                        <li >
+                            <a href="/docs/en/latest/">Documentation</a>
+                        </li>
+                        <li >
+                            <a href="/plugins">Plugins</a>
+                        </li>
+                        <li class="active">
+                            <a href="/blog" id="blog_button">Blog<span 
class="badge" id="new_blog_count"></span></a>
+                        </li>
+                        <li >
+                            <a href="/contribute">Contribute</a>
+                        </li>
+                        <li>
+                            <a href="/#getstarted">Get Started</a>
+                        </li>
+                        <li>
+                            <form class="navbar-form navbar-right" 
id="header-search-form" role="search">
+                                <div class="input-group">
+                                    
+                                        
+                                    
+                                    <input id="header-search-field" 
type="text" placeholder="Search '8.x' docs..." class="form-control hidden-xs" 
autocomplete="off">
+                                </div>
+                            </form>
+                        </li>
+                    </ul>
+                </div>
+            </div><!--/.navbar-collapse -->
+        </div>
+    </nav>
+    <div id="_fixed_navbar_spacer" style="padding-top:50px"></div>
+</header>
+
+<div class="page container">
+    <div class="blog">
+    <h1 class="blogHeader">
+    Blog
+    <span class="rss">
+        <img src="/static/img/subscribe.png"><a href="/feed.xml">RSS Feed</a>
+    </span>
+</h1>
+
+<div class="post">
+    <header>
+        <div class="title">Breaking changes coming to the iOS WebView in 
Apache Cordova</div>
+        <div class="author">By:
+            
+              <a href="https://twitter.com/shazron";>Shazron Abdullah</a>
+            
+        </div>
+        <div class="date">01 Aug 2018</div>
+    </header>
+    <section>
+        <div>
+            <p>With the announcement of the iOS 12 beta SDK at Apple’s WWDC 
2018, came the news that UIWebView, the webview originally bundled with the 
first iOS SDK, has been <a 
href="https://developer.apple.com/documentation/uikit/uiwebview";>deprecated</a>.
 What this means for iOS developers is that sometime in the future, Apple will 
remove UIWebView from their SDK, and developers should migrate to using the 
WKWebView component starting right now.</p>
+
+<h2>WebView Engine Plugins</h2>
+
+<p>Cordova iOS, starting with version 4, has anticipated this by moving the 
webview that is used by the platform into a plugin. The default webview that is 
used is still UIWebView, but you had the option to use WKWebView instead, with 
the <a 
href="https://github.com/apache/cordova-plugin-wkwebview-engine";>cordova-plugin-wkwebview-engine</a>
 plugin. Both the UIWebView and WKWebView webviews are plugins themselves, with 
the former included in the cordova-ios platform.</p>
+
+<p><img src="/static/img/blog/2018/arch-webview-engine.png" alt="Figure 1"></p>
+
+<h2>Cordova iOS 5 with WKWebView</h2>
+
+<p>Starting with Cordova iOS version 5, which is a planned upcoming release, 
we will ship both webview plugins with the cordova-ios platform, to enable 
developers to test and transition users to the new WKWebView component. Cordova 
iOS 5 will ship with a bridge webview plugin that can switch usage of the 
webview plugin used at runtime. Previously, you could only choose which webview 
you would use at build time.</p>
+
+<p><img src="/static/img/blog/2018/bridge-webview-engine.png" alt="Figure 
2"></p>
+
+<!--more-->
+
+<h2>Migration and Transition using the Bridge WebView Plugin</h2>
+
+<p>The developer can switch the webview used by setting a preference, that 
will be read at runtime when the app starts. Developers can transition users to 
the new WKWebView by user choice, in their app settings -- or randomly perhaps 
as an A/B test. This will give the developer and their users a chance to try 
out the new component, and they can back out and use UIWebView if there are any 
problems, without needing a new app release. This is intended to be used for 
testing and migration purposes only -- developers should aim to support only 
WKWebView functionality going forward.</p>
+
+<h2>Cordova iOS Future Release, WKWebView only</h2>
+
+<p>When UIWebView support has been removed in a future iOS SDK, we will aim to 
release a future Cordova iOS version, which will remove UIWebView support, and 
WKWebView will then be the default webview engine.</p>
+
+<table><thead>
+<tr>
+<th>Cordova iOS 4 &gt;&gt;&gt;</th>
+<th>Cordova iOS 5 &gt;&gt;&gt;</th>
+<th>Cordova iOS Future Release</th>
+</tr>
+</thead><tbody>
+<tr>
+<td></td>
+<td>UIWebView deprecated</td>
+<td>UIWebView removed</td>
+</tr>
+<tr>
+<td></td>
+<td>WKWebView Engine Plugin Integrated Into Platform</td>
+<td>WKWebView Engine Plugin only</td>
+</tr>
+<tr>
+<td></td>
+<td>Bridge WebView Plugin Added</td>
+<td>Bridge WebView Plugin Removed</td>
+</tr>
+</tbody></table>
+
+<h2>Limitations of WKWebView</h2>
+
+<p>There are <a 
href="https://mjtsai.com/blog/2018/06/20/webview-and-uiwebview-deprecated-in-favor-of-wkwebview/";>many
 limitations</a> of WKWebview, especially if you were using UIWebView 
previously. The limitations are:</p>
+
+<ol>
+<li>Cookies don&#39;t persist. This is a WebKit bug, but someone has
+created a plugin for a workaround. See
+<a href="https://issues.apache.org/jira/browse/CB-12074";>CB-12074</a></li>
+<li>Can&#39;t delete cookies. This is/was a WebKit bug (2015), we need to test
+for the iOS 11/12. See <a 
href="https://issues.apache.org/jira/browse/CB-11297";>CB-11297</a></li>
+<li>Can&#39;t execute JavaScript code in the background. There are several
+issues related to this. See
+<a href="https://issues.apache.org/jira/browse/CB-12815";>CB-12815</a></li>
+<li>XmlHttpRequests don&#39;t work, because of Cross-Origin Resource
+Sharing issue (CORS). There is a workaround plugin created by Oracle
+(UPL licensed, which is Apache-2.0 compatible). See
+<a href="https://issues.apache.org/jira/browse/CB-10143";>CB-10143</a></li>
+<li>Migration of localStorage from UIWebView. There is a migration
+plugin available. See <a 
href="https://issues.apache.org/jira/browse/CB-11974";>CB-11974</a></li>
+<li>iframes will not be supported any longer (they are now CORS restricted in 
WKWebView), and may be partially or completely broken. This may lead to 
incompatibilities with the same code in other Cordova platforms.</li>
+<li>Known issues with WKWebView on iOS pre-11 which will be deprecated and 
dropped in a future Cordova release</li>
+</ol>
+
+<p>There are several bugs that need to be resolved as well. The full list
+here: <a href="https://s.apache.org/QfsF";>https://s.apache.org/QfsF</a></p>
+
+<p>As you can see, WKWebView is not a direct drop-in replacement for 
UIWebView, you will need several plugins to patch functionality that is 
missing. There is also the <a 
href="https://github.com/apache/cordova-plugins/tree/wkwebview-engine-localhost";>local-webserver
 experimental plugin option</a>, which will not be graduated to a full plugin 
-- we will concentrate our efforts on supporting the main WKWebView engine 
plugin. </p>
+
+<p>Hopefully with more testing, and filing of bug reports with Apple for 
missing features, the WKWebView can be a full replacement for Cordova users.</p>
+
+        </div>
+    </section>
+    <footer>
+        <div class="row">
+            <div class="col-sm-6">
+                
+                    <a 
href="/announcements/2018/07/26/cordova-ios-4.5.5.html">Previous</a>
+                    <br>
+                    <br>
+                    <a class="title" 
href="/announcements/2018/07/26/cordova-ios-4.5.5.html">Cordova iOS 4.5.5 
Released!</a>
+                    <div class="date"> 26 Jul 2018 - By Chris Brody </div>
+                    <p class="content">
+                        We are happy to announce that Cordova iOS 4.5.5 has 
been released!...
+                    </p>
+                
+            </div>
+            <div class="col-sm-6">
+                
+            </div>
+        </div>
+    </footer>
+    <div class="disqus">
+        <div id="disqus_thread"></div>
+<script type="text/javascript">
+    /* * * CONFIGURATION VARIABLES * * */
+    var disqus_shortname = 'cordovablogs';
+
+    /* * * DON'T EDIT BELOW THIS LINE * * */
+    (function() {
+        var dsq = document.createElement('script'); dsq.type = 
'text/javascript'; dsq.async = true;
+        dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
+        (document.getElementsByTagName('head')[0] || 
document.getElementsByTagName('body')[0]).appendChild(dsq);
+    })();
+</script>
+<noscript>Please enable JavaScript to view the <a 
href="https://disqus.com/?ref_noscript"; rel="nofollow">comments powered by 
Disqus.</a></noscript>
+
+    </div>
+</div>
+
+</div>
+
+</div>
+
+<div class="blue-divider"></div>
+<footer>
+    <div class="container">
+        <div class="row">
+    <div class="col-sm-9">
+        <h1>More Resources</h1>
+        <div class="row">
+            <div class="col-sm-4">
+                <h2>General</h2>
+                <ul class="nav">
+                    <li>
+                        <a target="_blank" 
href="https://projects.apache.org/project.html?cordova";>Apache Project Page</a>
+                    </li>
+                    <li>
+                        <a 
href="http://www.apache.org/dyn/closer.cgi/cordova";>Source Distribution</a>
+                    </li>
+                    <li>
+                        <a target="_blank" 
href="http://www.apache.org/licenses/LICENSE-2.0";>License</a>
+                    </li>
+                    <li>
+                        <a href="/artwork">Artwork</a>
+                    </li>
+                </ul>
+            </div>
+            <div class="col-sm-4">
+                <h2>Development</h2>
+                <ul class="nav">
+                    <li><a target="_blank" 
href="https://github.com/apache?utf8=%E2%9C%93&amp;q=cordova-";>Source 
Code</a></li>
+                    <li><a target="_blank" 
href="https://issues.apache.org/jira/browse/CB/";>Issue Tracker</a></li>
+                    <li><a target="_blank" 
href="http://stackoverflow.com/questions/tagged/cordova";>Stack Overflow</a></li>
+                    <li><a href="/contact">Mailing List</a></li>
+                    <li><a href="/contribute/nightly_builds.html">Nightly 
builds</a></li>
+                </ul>
+            </div>
+            <div class="col-sm-4">
+                <h2>Apache Software Foundation</h2>
+                <ul class="nav">
+                    <li>
+                        <a target="_blank" href="http://www.apache.org/";>About 
ASF</a>
+                    </li>
+                    <li>
+                        <a target="_blank" 
href="http://www.apache.org/foundation/sponsorship.html";>Become a Sponsor</a>
+                    </li>
+                    <li>
+                        <a target="_blank" 
href="http://www.apache.org/foundation/thanks.html";>Thanks</a>
+                    </li>
+                    <li>
+                        <a target="_blank" 
href="http://www.apache.org/security/";>Security</a>
+                    </li>
+                </ul>
+            </div>
+        </div>
+    </div>
+    <div class="col-sm-3">
+        <h1>Contribute</h1>
+        <p style="padding-top:20px"><strong>Help Cordova move 
forward!</strong></p>
+        <p>Report bugs, improve the docs, or contribute to the code.</p>
+        <a href="/contribute" class="btn btn-lg btn-primary">
+            Learn More
+        </a>
+        <p style="padding-top:20px"> <a 
href="https://twitter.com/apachecordova"; class="twitter-follow-button" 
data-show-count="false">Follow @apachecordova</a></p>
+        <script async defer 
src="https://slack-cordova-io.herokuapp.com/slackin.js";></script>
+    </div>
+</div>
+<p class="copyright_text">
+    Copyright &copy; 2012, 2013, 2015 The Apache Software Foundation, Licensed 
under the <a target="_blank" 
href="http://www.apache.org/licenses/LICENSE-2.0";>Apache License, Version 
2.0</a>.<br/>
+    Apache and the Apache feather logos are <a target="_blank" 
href="http://www.apache.org/foundation/marks/list/";>trademarks</a> of The 
Apache Software Foundation.
+    <br/>
+    "Raleway" font used under license. For details see the <a 
href="/attributions/">attributions page</a>.
+</p>
+
+    </div>
+</footer>
+
+
+    <script defer type="text/javascript" src="/static/js/index.js"></script>
+    <script defer type="text/javascript" src="/static/js/twitter.js"></script>
+    
+    
+
+
+
+    
+
+
+<script type="text/javascript" 
src="https://cdn.jsdelivr.net/docsearch.js/1/docsearch.min.js";></script>
+<script type="text/javascript">
+    docsearch({
+        apiKey: '0a916ab198bd93d031aa70611271e42e',
+        indexName: 'cordova',
+        inputSelector: '#header-search-field',
+        algoliaOptions: { 'facetFilters': ["version:  8.x", "language: en"] }
+    });
+</script>
+
+</body>
+</html>

Modified: cordova/site/public/sitemap.xml
URL: 
http://svn.apache.org/viewvc/cordova/site/public/sitemap.xml?rev=1837686&r1=1837685&r2=1837686&view=diff
==============================================================================
--- cordova/site/public/sitemap.xml (original)
+++ cordova/site/public/sitemap.xml Thu Aug  9 02:48:54 2018
@@ -4,6 +4,11 @@
 <!-- posts -->
 
 <url>
+    
<loc>https://cordova.apache.org/news/2018/08/01/future-cordova-ios-webview.html</loc>
+</url>
+
+
+<url>
     
<loc>https://cordova.apache.org/announcements/2018/07/26/cordova-ios-4.5.5.html</loc>
 </url>
 

Modified: cordova/site/public/static/css/main.css
URL: 
http://svn.apache.org/viewvc/cordova/site/public/static/css/main.css?rev=1837686&r1=1837685&r2=1837686&view=diff
==============================================================================
--- cordova/site/public/static/css/main.css (original)
+++ cordova/site/public/static/css/main.css Thu Aug  9 02:48:54 2018
@@ -7079,6 +7079,8 @@ img#logo_top {
 .blog {
   /* landing page */
   /* blog post page */ }
+  .blog table, .blog td, .blog th {
+    border: 1px solid black; }
   .blog .blogHeader {
     color: #b58733;
     font-size: 30pt;

Added: cordova/site/public/static/img/blog/2018/arch-webview-engine.png
URL: 
http://svn.apache.org/viewvc/cordova/site/public/static/img/blog/2018/arch-webview-engine.png?rev=1837686&view=auto
==============================================================================
Binary file - no diff available.

Propchange: cordova/site/public/static/img/blog/2018/arch-webview-engine.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: cordova/site/public/static/img/blog/2018/bridge-webview-engine.png
URL: 
http://svn.apache.org/viewvc/cordova/site/public/static/img/blog/2018/bridge-webview-engine.png?rev=1837686&view=auto
==============================================================================
Binary file - no diff available.

Propchange: cordova/site/public/static/img/blog/2018/bridge-webview-engine.png
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Modified: cordova/site/public/static/js/index.js
URL: 
http://svn.apache.org/viewvc/cordova/site/public/static/js/index.js?rev=1837686&r1=1837685&r2=1837686&view=diff
==============================================================================
--- cordova/site/public/static/js/index.js (original)
+++ cordova/site/public/static/js/index.js Thu Aug  9 02:48:54 2018
@@ -77,6 +77,7 @@ function checkNotification() {
     var dates = [];
     if (lastVisit != "") {
         
+        dates.push('Wed, 01 Aug 2018 00:00:00 +0000');
         dates.push('Thu, 26 Jul 2018 00:00:00 +0000');
         dates.push('Mon, 23 Jul 2018 00:00:00 +0000');
         dates.push('Wed, 18 Jul 2018 00:00:00 +0000');



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cordova.apache.org
For additional commands, e-mail: commits-h...@cordova.apache.org

Reply via email to