Comparing version 0.2.0 to 0.3.0
@@ -0,1 +1,5 @@ | ||
0.3.0 / 2015-07-17 | ||
------------------ | ||
- added option for start page. See: https://github.com/jprichardson/reload/pull/20 | ||
0.2.0 / 2015-06-29 | ||
@@ -2,0 +6,0 @@ ------------------ |
@@ -15,2 +15,3 @@ var express = require('express') | ||
, delay = process.argv[6] | ||
, startPage = process.argv[7] | ||
@@ -23,8 +24,8 @@ | ||
app.get('/', function(req, res) { | ||
var indexFile = path.join(dir, 'index.html') | ||
fs.exists(indexFile, function(itDoes) { | ||
var startFile = path.join(dir, startPage) | ||
fs.exists(startFile, function(itDoes) { | ||
if (itDoes) | ||
sendhtml(indexFile, res) | ||
sendhtml(startFile, res) | ||
else | ||
res.send(404, "can't find index.html") | ||
res.send(404, "Can't find " + startPage) | ||
}) | ||
@@ -31,0 +32,0 @@ }) |
{ | ||
"name": "reload", | ||
"version": "0.2.0", | ||
"version": "0.3.0", | ||
"description": "Node.js module to refresh and reload your code in your browser when your code changes. No browser plugins required.", | ||
@@ -5,0 +5,0 @@ "repository": { |
@@ -148,9 +148,10 @@ reload | ||
-h, --help output usage information | ||
-V, --version output the version number | ||
-b, --browser Open in the browser automatically. | ||
-d, --dir [dir] The directory to serve up. Defaults to current dir. | ||
-e, --exts [extensions] Extensions separated by commas or pipes. Defaults to html,js,css. | ||
-p, --port [port] The port to bind to. Can be set with PORT env variable as well. Defaults to 8080 | ||
-t, --time [delay] How long (ms) should the browser wait before reconnecting? Defaults to 300 ms. | ||
-h, --help Output usage information | ||
-V, --version Output the version number | ||
-b, --browser Open in the browser automatically. | ||
-d, --dir [dir] The directory to serve up. Defaults to current dir. | ||
-e, --exts [extensions] Extensions separated by commas or pipes. Defaults to html,js,css. | ||
-p, --port [port] The port to bind to. Can be set with PORT env variable as well. Defaults to 8080 | ||
-t, --time [delay] How long (ms) should the browser wait before reconnecting? Defaults to 300 ms. | ||
-s, --start-page [start-page] Specify a start page. Defaults to index.html. | ||
@@ -157,0 +158,0 @@ ``` |
Sorry, the diff of this file is not supported yet
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
42641
95
193
1