用vue服务器渲染的问题
<% for (var chunk of webpack.chunks) {
for (var file of chunk.files) {
if (file.match(/\.(js|css)$/)) { %>
<link rel="<%= chunk.initial?'preload':'prefetch' %>" href="<%= htmlWebpackPlugin.files.publicPath + file %>" as="<%= file.match(/\.css$/)?'style':'script' %>"><% }}} %>
报错信息
/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:1097
throw result;
^
SyntaxError: Unexpected token =
at Function (<anonymous>)
at /home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:1089:12
at apply (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:74:25)
at /home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:1126:12
at apply (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:76:25)
at /home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:317:12
at template (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._lodash.template@4.4.0@lodash.template/index.js:1088:16)
at parseTemplate (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._vue-server-renderer@2.3.0@vue-server-renderer/build.js:1867:11)
at new TemplateRenderer (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._vue-server-renderer@2.3.0@vue-server-renderer/build.js:1938:7)
at createRenderer$1 (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._vue-server-renderer@2.3.0@vue-server-renderer/build.js:5658:26)
at createRenderer$$1 (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._vue-server-renderer@2.3.0@vue-server-renderer/build.js:6037:10)
at Object.createBundleRenderer (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._vue-server-renderer@2.3.0@vue-server-renderer/build.js:5969:20)
at createRenderer (/home/hldev/IdeaProjects/intelligence-system-frontend/server.js:36:43)
at require (/home/hldev/IdeaProjects/intelligence-system-frontend/server.js:30:20)
at Compiler.clientCompiler.plugin (/home/hldev/IdeaProjects/intelligence-system-frontend/build/setup-dev-server.js:32:9)
at Compiler.applyPlugins (/home/hldev/IdeaProjects/intelligence-system-frontend/node_modules/._tapable@0.2.6@tapable/lib/Tapable.js:61:14)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这关vue服务器渲染什么关系呢.
你好,请问这个问题后来解决了吗,我也是服务端渲染端时候碰到这个问题