【问题标题】:Receive error from Unexpected token Doctype Html从 Unexpected token Doctype Html 接收错误
【发布时间】:2017-04-26 04:14:59
【问题描述】:

我在我的项目中使用reactreact-router-domexpress。当我通过单击链接发送请求时,一切正常,但如果我通过浏览器发送请求,它就不起作用了。但是,对于浏览器中的某些请求,例如 http://localhost:8000/http://localhost:8000/admin 效果很好,但对于某些请求,例如 http://localhost:8000/admin/usershttp://localhost:8000/admin/account 效果不佳。

浏览器中的错误提示:bundle.js:1 Uncaught SyntaxError: Unexpected token < 它指向 .

【问题讨论】:

    标签: node.js reactjs express react-router


    【解决方案1】:

    我找到了我只需要编辑<script src="/bundle.js"></script>的解决方案。我已将bundle.js 编辑为/bundle.js

    【讨论】:

      猜你喜欢
      • 2019-01-09
      • 2015-04-20
      • 2022-11-10
      • 1970-01-01
      • 1970-01-01
      • 2016-10-17
      • 1970-01-01
      • 2022-01-07
      • 2022-09-25
      相关资源
      最近更新 更多