vbenjs / vue-vben-admin

A modern vue admin panel built with Vue3, Shadcn UI, Vite, TypeScript, and Monorepo. It's fast!
https://www.vben.pro
MIT License
24.24k stars 6.6k forks source link

同一页面内使用多个useForm造成页面卡死 #3451

Closed yiayi closed 5 months ago

yiayi commented 8 months ago

⚠️ 重要 ⚠️ 在进一步操作之前,请检查下列选项。如果您忽视此模板或者没有提供关键信息,您的 Issue 将直接被关闭

描述 Bug

在生产环境中同一页面内使用多个useForm造成页面卡死。

复现 Bug

在生产环境中同一页面内使用多个useForm造成页面卡死。开发环境本地可以使用多个,但是打包到生产环境后多个useForm会造成页面卡死。

系统信息

wangjue666 commented 8 months ago

demo示例也有多个useform呀 正常的呢 https://vben.vvbin.cn/#/comp/form/tabsForm

qichangleixin commented 8 months ago

你可能用了validate方法,现在版本有个bUG,你需要将useFormEvents.ts内validate方法的_nameList = nameList === Array.isArray(nameList) ? nameList : undefined;改为_nameList = Array.isArray(nameList) ? nameList : undefined;就可以了

xachary commented 8 months ago

项目里用到了3个useForm实例,也用了validate,庆幸暂时没出bug……

anncwb commented 5 months ago

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days