https://github.com/komomoo/vue-slim-loading
💇♀️ 简洁易用的 vue 加载组件,改造于 ElementUI/Loading
https://github.com/komomoo/vue-slim-loading
element-ui mobile-web v-loading vue-loading
Last synced: 5 months ago
JSON representation
💇♀️ 简洁易用的 vue 加载组件,改造于 ElementUI/Loading
- Host: GitHub
- URL: https://github.com/komomoo/vue-slim-loading
- Owner: komomoo
- License: mit
- Created: 2019-04-28T08:47:35.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2021-11-19T08:52:50.000Z (over 4 years ago)
- Last Synced: 2024-04-25T15:44:43.204Z (about 2 years ago)
- Topics: element-ui, mobile-web, v-loading, vue-loading
- Language: Vue
- Homepage: https://wannaxiao.github.io/vue-slim-loading/demo/dist/
- Size: 482 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# vue-slim-loading
## ✨ 特性
- 开箱即用/极简使用
- 体积:6k
## 🐠 示例&文档
[Demo](https://komomoo.github.io/vue-slim-loading/demo/dist/)
[Demo 源码](https://github.com/komomoo/vue-slim-loading/blob/master/demo/App.vue)
## 🚀 快速开始
1. 安装
```bash
yarn add vue-slim-loading # 或 npm i -S vue-slim-loading
```
2. 引入
```js
// main.js
import Loading from 'vue-slim-loading'
Vue.use(Loading)
```
3. 使用,请参考[Demo 源码](https://github.com/komomoo/vue-slim-loading/blob/master/demo/App.vue)
```html
瀑布的水逆流而上
```
## 🔌 API
### Directives
| 指令 | 说明 | 类型 | 默认值 |
| --------- | -------- | ------- | ------ |
| v-loading | 是否显示 | Boolean | false |
### Options
| 选项 | 说明 | 类型 | 默认值 |
| ------------ | ---------- | ------ | --------- |
| text | 文本显示 | String | null |
| color | 颜色 | String | '#409EFF' |
| maskClass | 遮罩样式类 | Array | null |
| loadingClass | 加载样式类 | Array | null |
| textClass | 文本样式类 | Array | null |
```js
// main.js
import Loading from 'vue-slim-loading'
Vue.use(Loading, { text: '加载中', color: 'green' })
```
### Attributes
> Attribute 将会覆盖 Option
| 属性 | 说明 | 类型 | 默认值 |
| ------------- | -------- | ------ | --------- |
| loading-text | 文本显示 | String | null |
| loading-color | 颜色 | String | '#409EFF' |
```html
瀑布的水逆流而上
```
### Slots
| 名称 | 说明 |
| -------- | -------------- |
| default | loading 内容 |
😉😘 如果它对你有所帮助,可以点一下 ⭐️Star ~
## License
[MIT](http://opensource.org/licenses/MIT)
Copyright (c) 2018-present, komo