tlacroix / NativePageTransitions

Native transitions like Slide and Flip for iOS and Android
4 stars 1 forks source link

Plugin incompatible with admob-plus-cordova #4

Open MaximPerry opened 2 years ago

MaximPerry commented 2 years ago

I got this plugin up and running. Transitions worked fine and as expected. Until I installed and setup the admob-cordova-plus plugin...

This broke the page transitions. You'll still see the transitions happening, but it won't load the new page; visually it will reload the page you're already on (page1), but behind the scene you will be interacting with the second page it was supposed to load (page2) that you don't see... It breaks the app.

Thoughts?

MaximPerry commented 2 years ago

Found a workaround.

Before calling window.plugins.nativepagetransitions.slide(), make sure you hide your admob-plus-cordova ad FIRST.

Example:

//index.html
<button onclick="slide('page2.html')">Page2</button>

//index.js
function slide(href) {

   admobBanner.hide();

   window.plugins.nativepagetransitions.slide({
        "href": href,
    });
}