Quantcast
Channel: Ionic Forum - Latest posts
Viewing all articles
Browse latest Browse all 230720

DOM not modified by var

$
0
0

why my DOM is not modified by this.tempo ?


{{ this.mensagemestimada }} {{ this.tempo }}

public temporizador(){
    var counter = 0;
    var timer = setInterval(function() {
    if( counter >= 10 ) {
      clearInterval( timer );
    }

    this.tempo = counter;
    console.log(this.tempo);
    console.log( counter);
    counter++;
    }, 1000);
  }

Viewing all articles
Browse latest Browse all 230720

Latest Images

Trending Articles



Latest Images

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