参考官方教程
安装了weex脚手架工具。
sudo cnpm install -g weex-toolkit
都成功了,nodejs是v6.10.1, npm是3.10.10,都是最新版本
可是只能使用weex init命令
我用weex compile src/foo.vue却报错。
直接输入weex回车也报同样的错
/usr/local/lib/node_modules/weex-toolkit/node_modules/[email protected]@xtoolkit/src/package/NpmPackage.js:50
throw new Error('resolve path error:'+this.path)
^
Error: resolve path error:/usr/local/lib/node_modules/weex-toolkit/node_modules/._weex-previewer
at NpmPackage.resolve (/usr/local/lib/node_modules/weex-toolkit/node_modules/[email protected]@xtoolkit/src/package/NpmPackage.js:50:23)
at Command.run (/usr/local/lib/node_modules/weex-toolkit/node_modules/[email protected]@xtoolkit/src/Command.js:43:13)
at XToolkit._done (/usr/local/lib/node_modules/weex-toolkit/node_modules/[email protected]@xtoolkit/src/xtoolkit.js:149:36)
at process.nextTick (/usr/local/lib/node_modules/weex-toolkit/node_modules/[email protected]@xtoolkit/src/xtoolkit.js:90:22)
at _combinedTickCallback (internal/process/next_tick.js:73:7)
at process._tickCallback (internal/process/next_tick.js:104:9)
at Module.runMain (module.js:606:11)
at run (bootstrap_node.js:393:7)
at startup (bootstrap_node.js:150:9)
at bootstrap_node.js:508:3
弄了一天,实在没办法了,来求助各位大神。
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…