Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/chemzqm/gulp-live-serve
gulp-serve with livereload inject
https://github.com/chemzqm/gulp-live-serve
Last synced: about 1 month ago
JSON representation
gulp-serve with livereload inject
- Host: GitHub
- URL: https://github.com/chemzqm/gulp-live-serve
- Owner: chemzqm
- License: mit
- Created: 2015-11-16T18:05:46.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2016-01-06T20:52:39.000Z (almost 9 years ago)
- Last Synced: 2024-11-07T01:16:02.351Z (about 2 months ago)
- Language: JavaScript
- Size: 24.4 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
gulp-live-serve
==========A fork of [gulp-serve](https://github.com/nkt/gulp-serve)
with [serve-index](https://www.npmjs.com/package/serve-index) for serving directory, use `config.root` for url
and [connect-livereload](https://www.npmjs.com/package/connect-livereload) for adding the livereload script to the response
**We can't use gulp-serve with middlewares option to do this, because serve-index must be the last middleware,
and connect-livereload should applied ahead of them **## Usage
``` js
var serve = require('gulp-live-serve')
serve({
root: './test/',
port: 3006,
livereload: {
port: 35729 // default port
}
})()
```## API
* `config.serveIndex` for options of serve-index
* `config.livereload` for options of connect-livereloadSee [gulp-serve#readme](https://github.com/nkt/gulp-serve#readme)