Closed sanxianlee closed 5 years ago
同问
这个有当时的截图吗?还有可以吧文件中的内容麻烦发下,以便于寻找问题
出现转换错误是可以试下
1、npm uninstall wx2ali -g
2、npm i wx2ali -g
之后重新转换下试试
同问
同问
你按照 https://github.com/foxitdog/wx2ali/issues/9#issuecomment-450119106 这个试试看,如果还有的话麻烦截图,或者把文件内容发下,我这边来查找问题。
你看看你的安装目录下有没有‘babel-plugin-transform-object-rest-spread‘这个模块
老铁 有的
问题复现,已经解决,请升级到1.1.7 。
Parse Error: ReferenceError: Unknown plugin "transform-object-rest-spread" specified in "base" at 0, attempted to resolve relative to "/Users/levent/coding/AntProjects/MegoTest" at /usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/file/options/option-manager.js:180:17 at Array.map ()
at Function.normalisePlugins (/usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/file/options/option-manager.js:158:20)
at OptionManager.mergeOptions (/usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/file/options/option-manager.js:234:36)
at OptionManager.init (/usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/file/options/option-manager.js:368:12)
at File.initOptions (/usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/file/index.js:212:65)
at new File (/usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/file/index.js:135:24)
at Pipeline.transform (/usr/local/lib/node_modules/wx2ali/node_modules/babel-core/lib/transformation/pipeline.js:46:16)
at Object.module.exports.replace (/usr/local/lib/node_modules/wx2ali/lib/JSApiPropReplace.js:10:19)
at wx2ant (/usr/local/lib/node_modules/wx2ali/index.js:370:27)