[Improvement] Toast: support Vue.use to register (#690)

This commit is contained in:
neverland
2018-03-14 11:47:46 +08:00
committed by GitHub
parent 8f2bd93786
commit 461b6732eb
11 changed files with 36 additions and 18 deletions

View File

@@ -1,6 +1,6 @@
import Waterfall from './directive.js';
const install = function(Vue) {
Waterfall.install = function(Vue) {
if (process.env.NODE_ENV !== 'production') {
console.warn('[Vant warn] Waterfall is deprecated, please use List component instread.');
}
@@ -8,5 +8,4 @@ const install = function(Vue) {
Vue.directive('WaterfallUpper', Waterfall('upper'));
};
Waterfall.install = install;
export default Waterfall;