AntmJS / antm

前端工程应用工具集, 文档工具:https://antmjs.github.io/antm/antm-doc/#/introduce
https://antmjs.github.io/antm/main
MIT License
51 stars 16 forks source link

@antmjs/doc编译报json解析错误 #159

Open loclink opened 1 year ago

loclink commented 1 year ago

错误描述:

执行 npx antm-doc-start 命令报错

这看起来是一个json文件解析报错,但我审查过json文件内容发现并无问题。

ERROR in ./.temp/wm-taro-design/all-search.json
Module parse failed: Cannot parse JSON: Unexpected token ";" (0x3B) in JSON at position 1718893 while parsing near "...样式变量 Border\"\n    }\n];\n"
File was processed with these loaders:
 * ../../node_modules/.pnpm/registry.npmmirror.com+swc-loader@0.2.3_@swc+core@1.3.95_webpack@5.89.0/node_modules/swc-loader/src/index.js
You may need an additional loader to handle the result of these loaders.

另外无论是在自己项目中单独使用@antmjs/doc,还是在@antmjs/vantui中执行docs:watch均存在此错误;而打包时执行npx antm-doc-build命令无报错且产物在浏览器中运行正常。

预期:

dev 模式正常

jhd2015 commented 8 months ago

你解决了吗