When running on localhost my application gets stuck on the “Loading…” screen and I receive the following errors in the chrome developer console:
Uncaught SyntaxError: Unexpected token <
react-dom@15.4.2.min.js:2 Uncaught SyntaxError: Unexpected token <
bundle.js:2 Uncaught SyntaxError: Unexpected token <
plotly-1.35.2.min.js:2 Uncaught SyntaxError: Unexpected token <
bundle.js:2 Uncaught SyntaxError: Unexpected token <
bundle.js:2 Uncaught SyntaxError: Unexpected token <
All of the above resources linked in my local “_dash-component-suits” directory link to the following HTML document instead of their intended contents. However, If I check the files locally, the content is correct.
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>My Project</title>
<link rel="stylesheet" href="https://unpkg.com/react-select@1.0.0-rc.3/dist/react-select.min.css">
<link rel="stylesheet" href="https://unpkg.com/react-virtualized@9.9.0/styles.css">
<link rel="stylesheet" href="https://unpkg.com/react-virtualized-select@3.1.0/styles.css">
<link rel="stylesheet" href="https://unpkg.com/rc-slider@6.1.2/assets/index.css">
<link rel="stylesheet" href="https://unpkg.com/dash-core-components@0.22.1/dash_core_components/react-dates@12.3.0.css">
<link rel="stylesheet" href="/myproject/static/myproject.css">
</head>
<body>
<div id="react-entry-point">
<div class="_dash-loading">
Loading...
</div>
</div>
<footer>
<script id="_dash-config" type="application/json">{"url_base_pathname": "/", "requests_pathname_prefix": "/myproject/"}</script>
<script src="/myproject/_dash-component-suites/dash_renderer/react@15.4.2.min.js?v=0.12.1"></script>
<script src="/myproject/_dash-component-suites/dash_renderer/react-dom@15.4.2.min.js?v=0.12.1"></script>
<script src="/myproject/_dash-component-suites/dash_html_components/bundle.js?v=0.10.1"></script>
<script src="/myproject/_dash-component-suites/dash_core_components/plotly-1.35.2.min.js?v=0.22.1"></script>
<script src="/myproject/_dash-component-suites/dash_core_components/bundle.js?v=0.22.1"></script>
<script src="/myproject/_dash-component-suites/dash_renderer/bundle.js?v=0.12.1"></script>
</footer>
</body>
</html>
Why are these files not linking correctly?