Closed swapneshk closed 9 years ago
Lineman runs its own express for serving static assets and proxying api requests to a backend that you define in config/application.js
under the server
key. IIRC, the /socket.io/socket.io.js
url you have in your frontend template is wired up by var io = require('socket.io')(server);
Given that the above line is in your express server and not Linemans dev server there is no way for Lineman to serve up that file.
To fix this you could modify config/server.js
to do what you want with socket.io, or just include the client-side library statically in vendor/js
.
Cheers :)
Following is my
app.js
file (backend- api end) - http://pastebin.com/4KRASm4aIn my frontend app template I am using following code to test if its working or not, but it is throwing error
Error: io is not defined
My application file looks like - http://pastebin.com/hDbrtQ1h
Let me know what I am doing wrong here if any.