Skip to content

Commit

Permalink
setup: run node server
Browse files Browse the repository at this point in the history
- add expressjs
- add morgan
- add angularjs
- run node server
  • Loading branch information
Maria Odessa P. Cubar committed Feb 17, 2016
1 parent 7bbfb20 commit ae9756c
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# libraries
node_modules/
bower_components/
7 changes: 7 additions & 0 deletions app/index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<html>
<body>
<div>Hello</div>
</body>

<script type="/bower_components/angular/angular.js"></script>
</html>
5 changes: 4 additions & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,8 @@
"bower_components",
"test",
"tests"
]
],
"dependencies": {
"angular": "angularjs#~1.5.0"
}
}
6 changes: 5 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,9 @@
"test": "npm test"
},
"author": "Maria Odessa P. Cubar",
"license": "ISC"
"license": "ISC",
"dependencies": {
"express": "^4.13.4",
"morgan": "^1.6.1"
}
}
15 changes: 15 additions & 0 deletions server.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
'use strict';

var express = require( 'express' );
var app = express();
var morgan = require( 'morgan' );

app.use( express.static( 'app' ) );
app.use( morgan( 'dev' ) );
app.use( '/bower_components', express.static( 'bower_components' ) );



app.listen( 8005 );

console.log( 'Listening to port 8005' );

0 comments on commit ae9756c

Please sign in to comment.