标签:div etop java 函数 exp names map script new
//tools.js
export const getUnion = (arr1, arr2) => {
return Array.from(new Set([...arr1, ...arr2]))
}
//调用页面
import { getUnion } from ‘@/libs/tools‘
// 示例
this.openedNames = getUnion(this.openedNames, this.getOpenedNamesByActiveName(name))
// 回调函数
getOpenedNamesByActiveName (name) {
return this.$route.matched.map(item => item.name).filter(item => item !== name)
}
标签:div etop java 函数 exp names map script new
原文地址:https://www.cnblogs.com/LFxanla/p/11171917.html