HexUI Mobile Library based on Vue1 fork from [mini-ui 1.x]
Mobile UI elements for Vue.js
# for Vue 1.x
npm i mint-ui@1 -S
# for Vue 2.0
npm i mint-ui -S
Import all components
import Vue from 'vue'
import Mint from 'mint-ui';
Vue.use(Mint);
Or import specific components (use babel-plugin-component)
import { Cell, Checklist } from 'mint-ui';
Vue.component(Cell.name, Cell);
Vue.component(Checklist.name, Checklist);
Equals to
import Vue from 'vue';
import Mint from 'mint-ui';
import 'mint-ui/lib/style.css';
Vue.use(Mint);
// import specified component
import MtRadio from 'mint-ui/lib/radio';
import 'mint-ui/lib/radio/style.css';
Vue.component(MtRadio.name, MtRadio);
- Auto import css file
- Modular import component
Installation
npm i babel-plugin-component -D
Usage
.babelrc
{
"plugins": ["other-plugin", ["component", [
{ "libraryName": "mint-ui", "style": true }
]]]
}
RawGit
- https://cdn.rawgit.com/ElemeFE/mint-ui/1.x/lib/index.js
- https://cdn.rawgit.com/ElemeFE/mint-ui/1.x/lib/style.css
NPMCDN
npm run dev
Please make sure to read the Contributing Guide before making a pull request.
MIT