san-cli 4.0.0 报错 #652
jinjingxuan
started this conversation in
San CLI
Replies: 4 comments 5 replies
-
我把项目中 node_modules / san-cli-config-webpack / node_modules / html-loader 删除了暂时解决了。 |
Beta Was this translation helpful? Give feedback.
3 replies
-
好使的低版本的 html-loader 的版本是多少? |
Beta Was this translation helpful? Give feedback.
1 reply
-
修好了,原因是高版本的 html-loader 默认把自闭合标签的斜杠给删了,而低版本的默认不删。 keepClosingSlash: true |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
san-cli 4.0.0 相关依赖中的 san-cli-config-webpack 中的 html-loader 版本是 ^1.3.2,且 san-cli-config-webpack / configs / base.js 设置优先从本地找 html-loader,没有再去全局找。导致的问题是 html-loader 优先使用了高版本,高版本有压缩功能,压缩后的 template 不能被 san 识别。
Beta Was this translation helpful? Give feedback.
All reactions