Push live changes to your end users
Last updated 7 years ago by architectd .
BSD · Repository · Original npm · Tarball · package.json
$ cnpm install hotfix 
SYNC missed versions from official npm registry.


Hotfix is a simple utility that pushes new fixes to the end client while they're still on your site.


Dev Dependencies


  • phantomjs - brew install phantomjs


  • browserify - npm i browserify -g
  • closure-compiler - brew install closure-compiler
  • coffee-script - npm i coffee-script -g


Assuming you have node.js installed, call:

npm i hotfix -g


There are a few ways to use hotfix:

Hotfix & Express

  1. First create a simple server:
var express = require("express"),
hotfix = require("hotfix"),
server = express();
  1. Next, add this script tag to the header of your HTML document:
    <script src="/hotfix/main.bundle.js"></script>
    Hello World!
  1. Open a browser, and navigate to http://localhost:8080.
  2. Make a change to your HTML doc, and call hotfix push-changes in the command line to refresh all open pages.

Hotfix & the command line

You can also use hotfix without node.js. To get started, run:

hotfix run-server --port=8080


Running a critical update that forces the user to refresh

hotfix push-changes --critical

Running an update against only certain clients (assuming you have something like assigned). Note that all mongodb-like queries are accepted since the hotfix client uses sift.

hotfix push-changes --filter="{\"app.version\": 19 }"

Customizing the end-user message

hotfix push-changes --message="This page is about to refresh due to connectivity issues"

CLI Usage

Usage: [command] --arg=value --arg2

  help                        Show help menu
  [cmd] help                  Show command help menu

  run-server                  Runs the hotfix http server
  push-changes                Pushes changes to all clients that are currently viewing the site

run-server command

Runs the hotfix http server

Usage: run-server

Optional Flags:
  --port=8080                 The http port to run hotfix on

push-changes command

Pushes changes to all clients that are currently viewing the site

Usage: push-changes

Optional Flags:
  --filter                    mongodb-style filter for each client
  --message=New updates a...  Message to display to the client.
  --critical                  Critical update - user account is force refreshed.
  --config=/usr/local/etc...  Configuration file for pubnub.

Current Tags

  • 0.0.4                                ...           latest (7 years ago)

4 Versions

  • 0.0.4                                ...           7 years ago
  • 0.0.3                                ...           7 years ago
  • 0.0.2                                ...           7 years ago
  • 0.0.1                                ...           7 years ago
Maintainers (2)
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 4
Dependencies (12)
Dev Dependencies (8)
Dependents (1)

Copyright 2014 - 2016 © |