docs: prettier all markdown files

This commit is contained in:
chenjiahan
2020-04-11 09:17:33 +08:00
committed by neverland
parent 48067f79db
commit 7f84f8a487
140 changed files with 4441 additions and 4723 deletions
+17 -17
View File
@@ -10,7 +10,7 @@ Vue.use(Lazyload);
// with options
Vue.use(Lazyload, {
lazyComponent: true
lazyComponent: true,
});
```
@@ -19,7 +19,7 @@ Vue.use(Lazyload, {
### Basic Usage
```html
<img v-for="img in imageList" v-lazy="img" >
<img v-for="img in imageList" v-lazy="img" />
```
```js
@@ -28,11 +28,11 @@ export default {
return {
imageList: [
'https://img.yzcdn.cn/vant/apple-1.jpg',
'https://img.yzcdn.cn/vant/apple-2.jpg'
]
'https://img.yzcdn.cn/vant/apple-2.jpg',
],
};
}
}
},
};
```
### Lazyload Background Image
@@ -48,13 +48,13 @@ Use `v-lazy:background-image` to set background url, and declare the height of t
```js
// set `lazyComponent` option
Vue.use(Lazyload, {
lazyComponent: true
lazyComponent: true,
});
```
```html
<lazy-component>
<img v-for="img in imageList" v-lazy="img" >
<img v-for="img in imageList" v-lazy="img" />
</lazy-component>
```
@@ -63,14 +63,14 @@ Vue.use(Lazyload, {
### Options
| Attribute | Description | Type | Default |
|------|------|------|------|
| loading | Src of the image while loading | *string* | - |
| error | Src of the image upon load fail | *string* | - |
| preload | Proportion of pre-loading height | *string* | - |
| attempt | Attempts count | *number* | `3` |
| listenEvents | Events that you want vue listen for | *string[]* | `scroll`... |
| adapter | Dynamically modify the attribute of element | *object* | - |
| filter | The image's listener filter | *object* | - |
| lazyComponent | Lazyload component | *boolean* | `false` |
| --- | --- | --- | --- |
| loading | Src of the image while loading | _string_ | - |
| error | Src of the image upon load fail | _string_ | - |
| preload | Proportion of pre-loading height | _string_ | - |
| attempt | Attempts count | _number_ | `3` |
| listenEvents | Events that you want vue listen for | _string[]_ | `scroll`... |
| adapter | Dynamically modify the attribute of element | _object_ | - |
| filter | The image's listener filter | _object_ | - |
| lazyComponent | Lazyload component | _boolean_ | `false` |
> See more[ vue-lazyload ](https://github.com/hilongjw/vue-lazyload)