屏幕宽度响应式
来源:5-4 通过 vueuse 优化处理方案

Pursuit001
2022-05-12
const w = ref(document.documentElement.clientWidth)
export const isMobileTerminal = computed(() => {
return w.value < PC_DEVICE_WIDTH
})
求佬们解答,这样写为啥也是没有响应式的?
写回答
1回答
-
Sunday
2022-05-12
你好
这样的代码应该是没有问题的,可能是其他的地方出现了错误。
032022-05-13
相似问题