vant/README.md
2017-08-04 16:33:45 +08:00

1.8 KiB
Raw Blame History

有赞logo

项目logo

A Vue.js 2.0 Mobile UI at YouZan

Build Status Coverage Status npm version downloads

访问中文版

Install

npm i -S vant

Usage

Import all components

import Vue from 'vue';
import vant from 'vant';
import 'vant/lib/vant-css/index.css';

Vue.use(vant);

On demand

import Vue from 'vue';
import { Button, Cell } from 'vant';
import 'vant/lib/vant-css/button.css';
import 'vant/lib/vant-css/cell.css';

Vue.component(Button.name, Button);
Vue.component(Cell.name, Cell);

Development

Add a new component

make init componentName

Start coding

Start development mode:

npm run dev

Visit http://localhost:8080 to see an example of all components.

Preview

You can scan the following QR code to access the demo

zanui_vue_mobile_qrcode

LICENSE

MIT