update Backtop

This commit is contained in:
Aresn 2017-05-26 09:45:05 +08:00
parent 987ca8cf21
commit 12f7b3a1e3

View file

@ -67,7 +67,7 @@
this.backTop = window.pageYOffset >= this.height;
},
back () {
var sTop = document.documentElement.scrollTop||document.body.scrollTop;
const sTop = document.documentElement.scrollTop || document.body.scrollTop;
scrollTop(window, sTop, 0, this.duration);
this.$emit('on-click');
}