评论功能中点击发送按钮后如何让input框中的内容自动清空呢

这是组件:
        <zwz-comment :comments="comments" @comment-like="commentLike" @input="input" @send-comment="commentSend"            v-model="commentText" @lower="lower" @reply="reply"></zwz-comment>
这是组件中:
<view class="comment-btm">
    <input type="text" :placeholder="placeholderComment" :focus="iptFocus" :value="value" @input="input"/>
        <button :type="commentText ? 'primary' : 'default'" @click="sendCourseComment(CommentId, superUserId, tier)">发送</button>
</view>
回答:
用 v-model 綁定值,發送后賦值空字符。
以上是 评论功能中点击发送按钮后如何让input框中的内容自动清空呢 的全部内容, 来源链接: utcz.com/p/935981.html



