微信小程序使用Vant Weapp中的Toast

首先在app.jsonindex.json中引入组件

"usingComponents": { "van-toast": "@vant/weapp/toast/index" }

然后再.wxml文件中写入:

最后在js文件中,注意一定要注意路径,我就在这路径这里搞了半天

 

 

猜你喜欢

转载自blog.csdn.net/qq_41588568/article/details/108316766