vant-ui.js
793 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import Vue from 'vue'
import {
Loading,
Lazyload,
Tab,
Tabs,
Toast,
Dialog,
Icon,
Form,
Field,
Switch,
Overlay,
Cell,
CellGroup,
ActionSheet,
Button,
Step,
Steps,
Checkbox,
Picker,
Popup,
Swipe,
SwipeItem,
Uploader
} from 'vant'
import NafmHeader from '@/components/NafmHeader'
import FooterBottom from '@/components/FooterBottom'
// 公共组建
[NafmHeader, FooterBottom].forEach(item => Vue.component(item.name, item));
// 默认vant组件
[Loading, Lazyload, Tab, Tabs, Toast, Dialog, Icon, Form, Field, Switch, Overlay, Cell, CellGroup, ActionSheet, Button, Step, Steps, Checkbox, Picker, Popup, Swipe, SwipeItem, Uploader].forEach(item => Vue.use(item))
// 先预制,后期做统一调整
Object.assign(window, {
Toast,
Dialog
})