You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Vue.js生产环境请求全失败,返回noscript错误如何解决?

Vue生产环境API请求返回noscript标签内容问题

我有一个Vue.js应用,调用部署在服务器上的Node.js(Express、MongoDB Atlas)REST API。本地运行Vue.js应用时一切正常,但将dist文件夹部署到服务器后,页面显示正常,但所有请求都返回如下内容:

We're sorry but Monthy replay doesn't work properly without JavaScript enabled. Please enable it to continue. --default-noscript-error

该信息来自Vue.js的index.html中的noscript标签:

<noscript>
    <strong>We're sorry but Monthy replay doesn't work properly without JavaScript enabled. Please 
     enable it to continue. --default-noscript-error</strong>
</noscript>

我已尝试以下操作:

  • 修改.htaccess文件
  • 更新Axios的baseURL
  • 验证代理配置(本地运行正常)
  • 直接调用API确认其可用

目前仍未解决问题,无法理解为何应用能正常显示,但请求返回noscript标签内容。

更新:问题仍未解决
在vue.config.js中将代理URI改为无效地址后,仍出现相同错误,推测生产环境的dist文件夹存在异常。

内容的提问来源于stack exchange,提问作者Raphael Rlt

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.20 07:27:27