-
Notifications
You must be signed in to change notification settings - Fork 2k
Open
Description
[扼要问题描述]
mpvue 版本号:
最小化复现代码:
[建议提供最小化可运行的代码:附件或文本代码]
index.vue
<template>
<view @click="add" key='container'>
<t-text :content="'t-text count: ' + count" :key="count" />
<text>\n real count: {{count}}</text>
</view>
</template>
<script>
import TText from "./t-text"
export default {
components: {
TText,
},
data() {
return {
count: 0,
}
},
methods: {
add() {
this.count++
},
}
}
</script>
t-text.vue:
<template>
<text>{{content}}</text>
</template>
<script>
export default {
props: ['content']
}
</script>
问题复现步骤:
- 点击view
观察到的表现:
- 第一行(组件)的数字先从0变成1,再瞬间变回0
- 第二行(原生text)的数据从0变成1
Metadata
Metadata
Assignees
Labels
No labels