Package Exports
- connect-livereload
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (connect-livereload) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
connect-livereload
connect middleware for adding the livereload script to the response. no browser plugin is needed. if you are happy with a browser plugin, then you don't need this middleware.
install
npm install connect-livereload --save-dev
use
this middleware can be used with a LiveReload server e.g. grunt-reload.
In your connect or express application add this after the static and before the dynamic routes:
var port = 35729;
app.use(require('connect-livereload')(port));
please see the examples for the app and Grunt configuration.
alternative
An alternative would be to install the LiveReload browser plugin.
credits
- The middleware code is mainly extracted from: grunt-contrib-livereload/util.js
- LiveReload Creator