Thanks to visit codestin.com
Credit goes to github.com

Skip to content

rhodey/bhr

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

bhr

Browserify hot reload server for single page applications. Chokidar watches for filesystem changes but you can hit ENTER to force reload. Sometimes webpack, etc is overkill.

Usage

The third and fourth examples show how to forward certain paths to api servers

npm install -g browserify-hot-reload
bhr main.js index.html assets/ -o dist/bundle.js
bhr main.js index.html assets/ -o dist/bundle.js -p 8080
bhr main.js index.html assets/ -o dist/bundle.js -p 8080 --http localhost:8081/api/a --http localhost:8082/api/b
bhr main.js index.html assets/ -o dist/bundle.js -p 8080 --https your.prod.server:443/api

You can also specify a command to run when any of the watched paths change

bhr main.js index.html assets/ -o dist/bundle.js -c "npm run something"

Envify

Envify is enabled so you can use process.env.VAR_NAME in source

License

Copyright 2025 - [email protected]

MIT

About

Browserify hot reload

Topics

Resources

License

Stars

Watchers

Forks