xu-li / cordova-plugin-wechat

A cordova plugin, a JS version of Wechat SDK
1.22k stars 509 forks source link

求解 ReferenceError: Can't find variable: Wechat #135

Closed gdamao closed 8 years ago

gdamao commented 8 years ago

我是在win7开发好后,android 测试没问题 ,生成 ionic platform add ios 然后把ios文件复制到苹果里面去xcode7.2打开, 测试结果第一个错误就是ReferenceError: Can't find variable: Wechat

xu-li commented 8 years ago

platform add以后,需要build,至少需要prepare才会拷贝资源到项目里面。

当然,最好的方法还是直接在Mac里面做。

zannet commented 7 years ago

遇到同样问题,在simulator下正常,真机测试Can't find variable: Wechat

wsx2018 commented 6 years ago

我是在mac上开发的,先开发的android版,微信登录和分享功能都没有问题,后面就build ios,装到真机上调试,也遇到了这个错误

wsx2018 commented 6 years ago

@xu-li ios版的用Safari调试发现wecaht.js没有导入,android版的就有导入

xu-li commented 6 years ago

不知道。没碰到过这种情况。

可以试试remove掉iOS platform,再remove掉这个插件,再重新装回来。

On Thu, Nov 16, 2017 at 11:11 AM heaven notifications@github.com wrote:

@xu-li https://github.com/xu-li ios版的用Safari调试发现wecaht.js没有导入,android版的就有导入

— You are receiving this because you were mentioned.

Reply to this email directly, view it on GitHub https://github.com/xu-li/cordova-plugin-wechat/issues/135#issuecomment-344802337, or mute the thread https://github.com/notifications/unsubscribe-auth/AAKekXAr5s4Nx3IEukIDvDAnVc5GpWseks5s26fkgaJpZM4G_cNn .