[this.type, this.appendType].includes('a1') || [this.type, this.appendType].includes('aa3'),因为后续可能还会有多种情况,例如includes('b1')...includes('c1')等
上面的表达式怎么用正则表达式匹配呢?
[this.type, this.appendType].includes('.*+')
这里不好打,[] ()等特殊符号要加转义符号
定义个数组
let arrs = ['a1','a2','a3'];
然后判断数组是否包含appendType
arrs.includes(this.appendType)