Socket.io不适用于部署到Heroku

时间:2018-08-07 13:49:05

标签: node.js heroku

我正在尝试使用使用socket.io的easyrtc创建一个应用程序。它可以在localhost上运行,但是当我将其部署到Heroku时会出现以下错误:

Failed to load resource: the server responded with a status of 404 (Not Found) (index):1

Refused to execute script from 'https://deep-nodejs.herokuapp.com/socket.io/socket.io.js' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.(index):4

Uncaught ReferenceError: io is not defined (index):4

我该如何解决?感谢您对此事的任何帮助。

0 个答案:

没有答案