Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70433

Unable to detach callback method from window object

$
0
0

@NaveedShaikh12 wrote:

Hi Everyone,

So I am required to execute a Payment script with callback methods upon entering PaymentView.ts file. These callbacks method [cancelCallback, errorCallback etc…] needs to be written with absolute uri. So I wrote them in the below fashion.

(window).cancelCallback = ()=>{
debugger;
console.log(“Cancel callback was created with window instance”);
this.loader.dismiss();
};

Now when I exit the PaymentView, and reenter the PaymentView, these methods gets piled up, as in the number of times I enter PaymentView, that number of times the callbackMethods will be fired. This is really serious issue, kindly post your thoughts on urgency.

Thanks!

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 70433

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>