Skip to content

Commit b4b386f

Browse files
committed
chore demo
1 parent da62b0d commit b4b386f

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

readme.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,15 @@ createApp(App)
2727
Use it in your template, your image will be lazy loaded.
2828

2929
```html
30-
<script setup lang="ts">
31-
const url = 'https://avatars.githubusercontent.com/u/59404696?v=4'
32-
</script>
33-
34-
<div>
35-
<img v-lazy="url"/>
36-
</div>
30+
<template>
31+
<div class="demo">
32+
<img
33+
v-for="it in 20"
34+
:key="it"
35+
v-lazy="'https://i.pinimg.com/474x/2e/b9/c1/2eb9c1a03b3b995e001915af141283b6.jpg?random=' + Math.random()"
36+
alt="img" />
37+
</div>
38+
</template>
3739
```
3840

3941
## Preview

0 commit comments

Comments
 (0)