combo-livereload
v0.1.0
Published
Automatic hot-swapping of assets during combo game development.
Downloads
5
Readme
combo-livereload
Automatic hot-swapping of assets during combo game development.
Usage
Made mostly to integrate with generator-combo
.
connect = require 'connect'
livereload = require 'combo-livereload'
app = connect()
.use livereload
.use connect.static './src'
server = require('http').createServer(app).listen(3000)
livereload.listen server # Sets up a socket.io context; REQUIRED.
gulp.watch ['src/assets/*.png', 'src/assets/*.jpg'], {}, (event) ->
livereload.reloadImage event.path.replace(__dirname + '/src/', '')