引入
cell swipe
左滑出现删除
示例
<template>
<div class="page-cell">
<div class="page-title">Cell Swipe</div>
<mt-cell-swipe
:key="index" v-for="(n,index) in 10"
:right="[
{
content: '删除',
style: { background: '#ff7900', color: '#fff'},
handler: () => deleteSection(index)
}
]"
title="11111">
</mt-cell-swipe>
</div>
</template>
<script>
export default {
methods: {
deleteSection(index) {
console.log(index);
},
}
};
</script>
显示