<span class="menuTitle" v-html="highLight(item.title)"> </span>
highLight (val) {
if (this.searchVal && val.includes(this.searchVal)) { //this.searchVal 是搜索框的内容
val = val.replace(this.searchVal, `<em style="background: yellow; color: #000; ">${this.searchVal}</span>`)
}
return val
}