sun-rice
Mobile UI elements for **Vue 2.0**
2,475
| Install | |
|---|---|
npm install sun-rice@1.0.4 |
|
| Latest Version: | 1.0.4 |
| Vue: | 2 |
| Last Updated: | Nov 14, 2019 |
| Links: | npm |
Maintainer: jinbaochuang
sun-rice
Mobile UI elements for Vue 2.0
Demo

Tutorial
点击查看使用教程
Usage
CDN 方式:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>sun-rice example</title>
<!-- import Vue.js -->
<script src="//vuejs.org/js/vue.min.js"></script>
<!-- import stylesheet -->
<link rel="stylesheet" href="//unpkg.com/sun-rice/dist/sun-rice.css">
<!-- import sun-rice -->
<script src="//unpkg.com/sun-rice/dist/sun-rice.umd.min.js"></script></head>
<body>
<div id="app">
<s-button type="default" @click="onClick">Click me!</s-button>
</div>
<script>
new Vue({
el: '#app',
methods: {
onClick() {
this.$dialog.alert({
message: '欢迎使用sun-rice ^_^'
})
}
}
})
</script>
</body>
</html>
npm 方式:
npm i sun-rice -S
Import all components.
import Vue from 'vue'
import SunRice from 'sun-rice'
import 'sun-rice/dist/sun-rice.css'
Vue.use(SunRice)
Or import specified component. (Use babel-plugin-component)
import { SunCell } from 'sun-rice'
Vue.component(SunCell.name, SunCell)
babel-plugin-component
- Auto import css file
- Modular import component
Installation
npm i babel-plugin-component -D
Usage
.babelrc
{
"plugins": [
"other-plugin",
["component", [{ "libraryName": "sun-rice", "style": true }]]
]
}
Development
npm run dev
Contribution
Please make sure to read the Contributing Guide before making a pull request.
Version History
| Version | Released | Vue | License |
|---|---|---|---|
| 1.0.4 | 2.5.2 | ||
| 1.0.3 | 2.5.2 | ||
| 1.0.2 | 2.5.2 | ||
| 1.0.1 | 2.5.2 | ||
| 1.0.0 | 2.5.2 | ||
| 0.1.21 | ^2.6.10 | ||
| 0.1.20 | ^2.6.10 | ||
| 0.1.19 | ^2.6.10 | ||
| 0.1.18 | ^2.6.10 | ||
| 0.1.17 | ^2.6.10 | ||
| 0.1.16 | ^2.6.10 | ||
| 0.1.15 | ^2.6.10 | ||
| 0.1.14 | ^2.6.10 | ||
| 0.1.13 | ^2.6.10 | ||
| 0.1.12 | ^2.6.10 | ||
| 0.1.11 | ^2.6.10 | ||
| 0.1.10 | ^2.6.10 | ||
| 0.1.9 | ^2.6.10 | ||
| 0.1.8 | ^2.6.10 | ||
| 0.1.7 | ^2.6.10 | ||
| 0.1.6 | ^2.6.10 | ||
| 0.1.5 | ^2.6.10 | ||
| 0.1.4 | ^2.6.10 | ||
| 0.1.3 | ^2.6.10 | ||
| 0.1.2 | ^2.6.10 | ||
| 0.1.1 | ^2.6.10 | ||
| 0.0.76 | ^2.6.10 | ||
| 0.0.72 | ^2.6.10 | ||
| 0.0.71 | ^2.6.10 | ||
| 0.0.70 | ^2.6.10 |
Showing the latest 30 of 94. See every release on npm