效果如下:
代码:
- 说明:用到了mint-ui,需要先安装
- mt-button的导入: import { Button } from ‘mint-ui’
- mt-button的使用: Vue.component(Button.name, Button)
- 更多 http://mint-ui.github.io/
// comment.vue
<template>
<div class="comment-container">
<hr>
<h3 class="title">发表评论</h3>
<textarea
placeholder="请输入要BB的内容(最多吐槽120字)"
maxlength="120"
></textarea>
<mt-button
type="primary"
size="large"
>发表评论</mt-button>
<div class="cmt-list">
<div class="cmt-item">
&