dwqe21
dwqe21
  • 发布:2018-08-27 16:16
  • 更新:2018-11-23 00:37
  • 阅读:2309

uni-migration 将微信小程序转换为 uniapp 提示出错

分类:uni-app

命令

uni-migration -p uniapp wechat wechat-uniapp  

提示:

TypeError: Cannot read property 'forEach' of undefined  
    at rewriteNode (~/Documents/uni-migration/lib/weapp/transform/page-rewriter/template-rewriter/node.js:1:3649)  
    at rewrite (~/Documents/uni-migration/lib/weapp/transform/page-rewriter/template-rewriter/index.js:1:630)  
    at Object.rewriter [as page] (~/Documents/uni-migration/lib/weapp/transform/page-rewriter/index.js:1:3447)  
    at ~/Documents/uni-migration/lib/weapp/index.js:1:4826  
    at Array.every (<anonymous>)  
    at Object.transform (~/Documents/uni-migration/lib/weapp/index.js:1:3725)  
    at module.exports (~/Documents/uni-migration/lib/index.js:1:821)  
    at Object.<anonymous> (~/Documents/uni-migration/bin/uni-migration.js:42:3)  
    at Module._compile (internal/modules/cjs/loader.js:689:30)  
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)  

请问怎么解决?

2018-08-27 16:16 分享
已邀请:

最佳回复

DCloud_heavensoft

DCloud_heavensoft

抱歉,这个入口引导下版会下线。
这个是转换老版nml和快应用用的,转换后并非100%可用,需要继续修改转换后的代码。
目前并没有小程序转换为新版uni-app的功能。
小程序如果是基于mpvue的,参考这里可快速改造为uni-apphttp://ask.dcloud.net.cn/article/34945
如果不是mpvue,参考这个网友分享的转换心得http://ask.dcloud.net.cn/article/35020

dwqe21

dwqe21 (作者)

@fxy060608

1138320887@qq.com

1138320887@qq.com

好像不好用。我试着小程序转快应用失败了

要回复问题请先登录注册