taro 报错及解决

1、解决:taro 升级到最新版(npm install -g @tarojs/cli

错误  组件编译  组件src/pages/xxx/xxx.tsx编译失败!
TypeError: callee.node.arguments is not iterable
    at loopComponents.forEach (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/render.js:652:48)
    at Map.forEach (<anonymous>)
    at RenderParser.handleLoopComponents (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/render.js:633:33)
    at new RenderParser (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/render.js:842:14)
    at Transformer.parseRender (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/class.js:488:19)
    at Transformer.compile (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/class.js:500:14)
    at new Transformer (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/class.js:102:14)
    at transform (/usr/local/lib/node_modules/@tarojs/cli/node_modules/@tarojs/transformer-wx/lib/src/index.js:435:14)
    at buildSingleComponent (/usr/local/lib/node_modules/@tarojs/cli/src/weapp.js:1511:29)
    at Promise.all.componentPathList.map.componentObj (/usr/local/lib/node_modules/@tarojs/cli/src/weapp.js:1416:60)

2、解决:taro 升级到最新版(npm install -g @tarojs/cli

错误  页面编译  页面/src/pages/home/index编译失败!
TypeError: Cannot read property 'wxss' of undefined
    at buildDepComponentsResult.map.item (/usr/local/lib/node_modules/@tarojs/cli/src/weapp.js:1423:23)
    at Array.map (<anonymous>)
    at getDepStyleList (/usr/local/lib/node_modules/@tarojs/cli/src/weapp.js:1422:44)
    at buildSinglePage (/usr/local/lib/node_modules/@tarojs/cli/src/weapp.js:1264:28)

posted on 2019-04-17 20:00  cag2050  阅读(1196)  评论(0编辑  收藏  举报

导航