Permalink
Browse files

working server

  • Loading branch information...
1 parent a0470a3 commit 2606a524ce06fe2f025ad33932dc0ec82ee5dca9 @indutny committed Nov 1, 2010
Showing with 22 additions and 5 deletions.
  1. +10 −5 core/mapchat
  2. +1 −0 pub/css/main.less
  3. +10 −0 pub/index.html
  4. +1 −0 pub/js/main.js
View
@@ -4,12 +4,17 @@ var connect = require('connect'),
io = require('socket.io'),
route_api = require('./lib/routes/api'),
route_user = require('./lib/routes/user');
-
+
var server = connect.createServer(
connect.bodyDecoder(),
- connect.format(),
- connect.compiler(),
+ connect.cookieDecoder(),
+ connect.methodOverride(),
+ connect.compiler({src: __dirname + '/../pub', enable: ['less'] }),
connect.session(),
- connect.router(route_user)
- connect.router(route_api)
+ connect.router(route_user),
+ connect.router(route_api),
+ connect.cache(),
+ connect.staticProvider(__dirname + '/../pub')
);
+
+server.listen(8080);
View
@@ -0,0 +1 @@
+
View
@@ -0,0 +1,10 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <link rel="stylesheet" href="css/main.less" type="text/css" />
+ <title>MapChat</title>
+ </head>
+ <body>
+ <script type="text/javascript" src="js/main.js"></script>
+ </body>
+</html>
View
@@ -0,0 +1 @@
+

0 comments on commit 2606a52

Please sign in to comment.