Skip to content

Commit

Permalink
Adding example to events page
Browse files Browse the repository at this point in the history
  • Loading branch information
weotch committed Sep 20, 2022
1 parent 6c862f4 commit aadd3e3
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 0 deletions.
1 change: 1 addition & 0 deletions demo/components/demos/events/v-model.vue
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,6 @@ button
border 1px solid currentColor
padding .5em
border-radius .5em
margin-bottom 1em
</style>
28 changes: 28 additions & 0 deletions demo/content/events.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,34 @@ You can set the initial index with `:value`. Or use `v-model` to track the curre

<demos-events-v-model></demos-events-v-model>

```vue
<template>
<div>
<ssr-carousel v-model='page'>
<slide :index='1'></slide>
<slide :index='2'></slide>
<slide :index='3'></slide>
</ssr-carousel>
<span class="now">Current Page: {{ page + 1 }}</span>
<button @click='page--'>Back</button>
<button @click='page++'>Next</button>
</div>
</template>
<script>
export default {
data() {
return {
page: 1,
};
},
};
</script>
```

## All Events

Interact with demo to view events
Expand Down

0 comments on commit aadd3e3

Please sign in to comment.