ember.js - calling set on destroyed object setInterval in acceptance tests -


i know there 5 topics same name here, seems unrelated case: i'm getting error in acceptance tests, , reason countdown component built ember.run.later.

maybe know how cure that?

just should stop timer upon element destruction. ember, of course, doesn't handle himself.

startcountdown: function() {   let handler;   //...    handler = setinterval(...);   this.set('handler', handler); }    teardown: function() {     clearinterval(this.get('handler'));   }.on('willdestroyelement') 

Comments

Popular posts from this blog

OpenCV OpenCL: Convert Mat to Bitmap in JNI Layer for Android -

android - org.xmlpull.v1.XmlPullParserException: expected: START_TAG {http://schemas.xmlsoap.org/soap/envelope/}Envelope -

python - How to remove the Xframe Options header in django? -