Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

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

  • Loading branch information...
commit 7a1525c5688774254f6555ce66e9386b914977eb 1 parent fe99eb7
@tj tj authored
Showing with 3 additions and 3 deletions.
  1. +1 −1  docs/guide.md
  2. +2 −2 lib/express/view.js
View
2  docs/guide.md
@@ -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
4 lib/express/view.js
@@ -86,7 +86,7 @@ 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
@@ -94,7 +94,7 @@ function viewRoot(app) {
exports.watcher = function(interval){
interval = interval === true
- ? 300000
+ ? 500
: interval;
(function cache(dir){
fs.readdir(dir, function(err, files){
Please sign in to comment.
Something went wrong with that request. Please try again.