1.1.6 • Published 2 years ago
vtown-mobile-common-component v1.1.6
vtown-mobile-common-component
介绍
微棠移动端h5专用组件库
使用 vant2 脚手架搭建
快速上手
安装
# 通过 npm
npm i vtown-mobile-common-component
# 通过 yarn
yarn add vtown-mobile-common-component
# 通过 pnpm
pnpm add vtown-mobile-common-component
引入组件
在不使用插件的情况下,可以手动引入需要的组件。
# 方式一:手动按需引入组件
import Button from 'vtown-mobile-common-component';
支持一次性导入所有组件,引入所有组件会增加代码包体积。
# 方式二:导入所有组件
import VtownMobile from 'vtown-mobile-common-component';
Vue.use(VtownMobile);
Tips: 配置按需引入后,将不允许直接导入所有组件。