Permalink
Browse files

Defaulting app.enable("reload views") to 500ms

  • Loading branch information...
tj committed Jul 27, 2010
1 parent fe99eb7 commit 7a1525c5688774254f6555ce66e9386b914977eb
Showing with 3 additions and 3 deletions.
  1. +1 −1 docs/guide.md
  2. +2 −2 lib/express/view.js
View
@@ -85,7 +85,7 @@ Express supports the following settings out of the box:
* _views_ Root views directory defaulting to **CWD/views**
* _view engine_ Default view engine name for views rendered without extensions
* _reload views_ Reloads altered views, by default watches for _mtime_ changes with
- with a 5 minute interval. Example: _app.set('reload views', 60000);_
+ with a 500 millisecond interval.
### Routing
View
@@ -86,15 +86,15 @@ function viewRoot(app) {
/**
* Setup view reloading, checking at the given `interval`
- * which defaults to 5 minutes.
+ * which defaults to 500 milliseconds.
*
* @param {Numbers} interval
* @api private
*/
exports.watcher = function(interval){
interval = interval === true
- ? 300000
+ ? 500
: interval;
(function cache(dir){
fs.readdir(dir, function(err, files){

0 comments on commit 7a1525c

Please sign in to comment.