import Toast from "../../wxcomponents/@vant/weapp/toast/toast";
Toast('我是提示文案,建议不超过十五字~');
Vant Weapp 版本
1.11.4
描述一下你遇到的问题。
在微信小程序中, 使用 uni-app 框架环境、vue3的版本、
在编译中 Toast 和 图片上传组件 只能有一个成功,必有一个报错。
错误为:
上传图片报错为:
TypeError: (0 , _validator.isPlainObject) is not a function
at pickExclude (utils.js? [sm]:31)
at utils.js? [sm]:28
at Array.map ()
at formatImage (utils.js? [sm]:28)
at Object.success (utils.js? [sm]:62)
at Function.I.forEach.v. (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at :13230/appservice/
at Object.success (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at a (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at qu (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)(env: Windows,mp,1.06.2401020; lib: 3.4.2)
Toast 错误为:
vendor.js? [sm]:2836 TypeError: wxcomponents__vant_weapp_toast_toast.Toast is not a function
at showPopup (power.js? [sm]:45)
at callWithErrorHandling (vendor.js? [sm]:2778)
at callWithAsyncErrorHandling (vendor.js? [sm]:2786)
at invoke (vendor.js? [sm]:5875)
at yi.invoker [as e0] (vendor.js? [sm]:5881)
at yi. (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at o.safeCallback (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at o.call (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at r (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1(env: Windows,mp,1.06.2401020; lib: 3.4.2)
偶尔 Toast 好用 偶尔上传图片的 after-read 方法好用 这是为什么呢?
重现链接
import Toast from "../../wxcomponents/@vant/weapp/toast/toast";
Toast('我是提示文案,建议不超过十五字~');
Vant Weapp 版本
1.11.4
描述一下你遇到的问题。
在微信小程序中, 使用 uni-app 框架环境、vue3的版本、 在编译中 Toast 和 图片上传组件 只能有一个成功,必有一个报错。 错误为: 上传图片报错为: TypeError: (0 , _validator.isPlainObject) is not a function at pickExclude (utils.js? [sm]:31) at utils.js? [sm]:28 at Array.map ()
at formatImage (utils.js? [sm]:28)
at Object.success (utils.js? [sm]:62)
at Function.I.forEach.v. (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at :13230/appservice/
at Object.success (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at a (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at qu (WAServiceMainContext.js?t=wechat&s=1714290110651&v=3.4.2:1)(env: Windows,mp,1.06.2401020; lib: 3.4.2)
Toast 错误为:
vendor.js? [sm]:2836 TypeError: wxcomponents__vant_weapp_toast_toast.Toast is not a function
at showPopup (power.js? [sm]:45)
at callWithErrorHandling (vendor.js? [sm]:2778)
at callWithAsyncErrorHandling (vendor.js? [sm]:2786)
at invoke (vendor.js? [sm]:5875)
at yi.invoker [as e0] (vendor.js? [sm]:5881)
at yi. (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at o.safeCallback (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at o.call (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at r (WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1)
at WASubContext.js?t=wechat&s=1714290110651&v=3.4.2:1(env: Windows,mp,1.06.2401020; lib: 3.4.2)
偶尔 Toast 好用 偶尔上传图片的 after-read 方法好用 这是为什么呢?
重现步骤
1.点击按钮
设备/浏览器
No response