Skip to content

Commit

Permalink
Caching static resources
Browse files Browse the repository at this point in the history
  • Loading branch information
gastaldi committed Jun 2, 2015
1 parent 4eb975a commit 8cc79e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server.js
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ app.get('/sh', function(req,res) {
});
});

app.get(/\/?.*(\/1.x\/?)|(.js|.css|.png|.ico|.html|.jpg)/, restify.serveStatic({default: 'index.html', directory: './app/'}));
app.get(/\/?.*(\/1.x\/?)|(.js|.css|.png|.ico|.html|.jpg)/, restify.serveStatic({default: 'index.html', directory: './app/', cache: true}));

// Everything except the already defined routes. IMPORTANT: this should be the last route
app.get(/\/?.*/, function(req,res) {
Expand Down

0 comments on commit 8cc79e6

Please sign in to comment.