support BackTop to 2.0

This commit is contained in:
mod 2017-03-07 10:03:11 +08:00
parent 4aec6a66bb
commit 1d8f776752
6 changed files with 24 additions and 4 deletions

View file

@ -35,7 +35,7 @@
backTop: false
};
},
ready () {
mounted () {
window.addEventListener('scroll', this.handleScroll, false);
window.addEventListener('resize', this.handleScroll, false);
},

View file

@ -3,7 +3,7 @@ import 'core-js/fn/array/find-index';
import Affix from './components/affix';
import Alert from './components/alert';
// import BackTop from './components/back-top';
import BackTop from './components/back-top';
import Badge from './components/badge';
import Breadcrumb from './components/breadcrumb';
import Button from './components/button';
@ -49,7 +49,7 @@ import locale from './locale';
const iview = {
Affix,
Alert,
// BackTop,
BackTop,
Badge,
Breadcrumb,
BreadcrumbItem: Breadcrumb.Item,