需求: 想三邊高度一致, 主要看截圖

代碼
html:使用 this.$refs.inforTitleR.clientHeight 獲取該元素的高度

js部分
// 先data里定義
comHeight: "126px",
// 數據賦值函數里 判斷高度 讓高度都==右側的高度 注意減去增加的padding20 this.$nextTick(function() { this.comHeight = this.$refs.inforTitleR.clientHeight - 20 + "px"; });
watch: { comHeight: { handler(newVal, oldVal) { if (newVal) { this.comHeight = newVal; } } } },

css隨便都可以,根據UI圖等

