tiny-vue/examples/docs/resources/pc/demo/anchor/basic-usage.vue

51 lines
1006 B
Vue

<template>
<tiny-anchor :links="links"></tiny-anchor>
</template>
<script>
import { Anchor } from '@opentiny/vue'
export default {
components: {
TinyAnchor: Anchor
},
data() {
return {
links: [
{
key: 'demonstrate',
link: '#demonstrate',
title: '演示',
children: [
{
key: 'basic-usage',
link: '#basic-usage',
title: 'Basic Usage'
},
{
key: 'is-affix',
link: '#is-affix',
title: 'Is Affix'
},
{
key: 'set-container',
link: '#set-container',
title: 'Set Container'
},
{
key: 'on-change',
link: '#on-change',
title: 'On Change'
}
]
},
{
key: 'api',
link: '#api',
title: 'Api'
}
]
}
}
}
</script>