sharejs 0.6 with express4
- Dominant language
- JavaScript
- Stars
- 5k
- Forks
- 454
- PR merge metrics
- No merged PRs in 30d
Description
use sharejs 0.6 with express, always get erro... the sharejs cannot be correct loaded on client side, it comes out:
Resource interpreted as Script but transferred with MIME type text/html: "http://localhost:3000/channel/bcsocket.js". localhost/:170
Resource interpreted as Script but transferred with MIME type text/html: "http://localhost:3000/share/textarea.js". localhost/:172
Resource interpreted as Script but transferred with MIME type text/html: "http://localhost:3000/share/share.js". localhost/:171
Uncaught SyntaxError: Unexpected token < bcsocket.js:1
Uncaught SyntaxError: Unexpected token < share.js:1
Uncaught SyntaxError: Unexpected token < textarea.js:1
Uncaught ReferenceError: sharejs is not defined (index):18
my client side is like the demo in the get started doc
and server side:
var sharejs = require('share').server;
var options = {db: {type: 'none'}};
var app = express();
......
var server = http.createServer(app);
sharejs.attach(app, options);
server.listen(app.get('port'), function () {
console.log('Express server listening on port ' + app.get('port'));
});
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.