只需调用数组的方法Array.from配合泛型即可:
index.value = Array.from<HTMLElement>(
document.querySelectorAll(".el-overlay")
).at(-1)?.style.zIndex;
只需调用数组的方法Array.from配合泛型即可:
index.value = Array.from<HTMLElement>(
document.querySelectorAll(".el-overlay")
).at(-1)?.style.zIndex;