通过filter 过滤出搜索信息

/**
* @description 根据模板名称搜索模板
*/
private search() {
const SEARCH_TEMPLET = toArray(this.ALL_TEMPLET)
.filter((templet: any) => templet.title.includes(this.searchValue));
this.tableData = SEARCH_TEMPLET;
}
原文地址:https://www.cnblogs.com/aisiqi-love/p/10142093.html