You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2019/11/29 02:41:27 UTC

[GitHub] [cordova-plugin-inappbrowser] thachhn opened a new issue #585: [iOS] WKWebview - Back button in location bar is always enabled

thachhn opened a new issue #585: [iOS] WKWebview - Back button in location bar is always enabled
URL: https://github.com/apache/cordova-plugin-inappbrowser/issues/585
 
 
   ### Issue Type
   
   - [x ] Bug Report
   - [ ] Feature Request
   - [ ] Support Question
   
   ## Description
   Click on back button of location bar or `history.back()` or `history.go(-1)`, the back button of location bar is always enabled. User can click on back button or call `history.back()` or `history.go(-1)`, with no endpoint.
   
   It looks like the back action always pushes new URL to history stack instead going back
   
   ## Information
   I'm using `usewkwebview=yes`. When open inappbrowser in the first time, back button is disabled. But when click on some URL, the back button is always enabled.
   
   I checked this function in CDVWKInAppBrowser.m
   ```
   - (void)webView:(WKWebView *)theWebView didFinishNavigation:(WKNavigation *)navigation
   ```
   
   `theWebView.canGoBack;` is always returns true after the first redirect
   
   ### Command or Code
   ```
   const target = '_blank';
       const options = [
         'location=yes',
         'hidden=no',
         'hideurlbar=no',
         'toolbar=yes',
         'hidenavigationbuttons=no',
         'zoom=no',
         'transitionstyle=crossdissolve',
         'enableViewportScale=yes',
         'usewkwebview=yes',
         'beforeload=get'
       ];
       inAppBrowserRef = window.cordova.InAppBrowser.open(url, target, options.join());
   ```
   
   ### Environment, Platform, Device
   Cordova ver 9
   
   Platform: iOS 13,
   Device: iPhone 7
   
   package.json
   cordova-plugin-inappbrowser: "3.1.0"
   cordova-plugin-wkwebview-engine: "1.2.1"
   
   
   ## Checklist
   
   - [x ] I searched for already existing GitHub issues about this
   - [x ] I updated all Cordova tooling to their most recent version
   - [x ] I included all the necessary information above
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

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