Skip to content
Realtime Message Bus for the Web. Javascript Implementation
Branch: master
Clone or download
Latest commit 074a17d Aug 9, 2018
Type Name Latest commit message Commit time
Failed to load latest commit information.
bench add sorting bench Dec 8, 2016
bin format with standard (js) Jan 18, 2016
build bump rev 1.0.6 Jan 18, 2016
doc Support Websocket options (#293) Feb 17, 2017
examples improve balls example Mar 21, 2017
lib Ws dos fix (#321) Aug 9, 2018
test Added additional return type tests (#319) May 4, 2018
.codeclimate.yml add codeclimate config with eslint rules for standard js Oct 5, 2016
.doclets.yml add package json to doclets file Dec 30, 2015
.gitignore add chat example Jun 15, 2015
.jshintrc add jshint resource Feb 17, 2015
.travis.yml Node 8 fix (#315) Sep 26, 2017
LICENSE use github template Apr 9, 2015
Makefile use uglify-js instead of uglify Jun 1, 2015 JavaScript (#317) Aug 7, 2018 ignore all node_modules paths Apr 15, 2015
bower.json bump rev 1.0.2 Sep 13, 2015
jet-todo.png replace todo-app iframe with image link May 6, 2015
package.json 1.5.6 Aug 9, 2018


Join the chat at npm version Build Status Code Climate Coverage Status js-standard-style deps

This is Jet for JavaScript. Jet is the hybrid of an In-Memory Database and a Realtime Push-Framework. Node and Browsers are supported (using Browserify).


Start a Daemon:

$ jetd.js

Provide Content:

var jet = require('node-jet');

// connect to daemon
var peer = new jet.Peer({
  url: 'ws://localhost:11123' 

// provide methods/factories/services/actions/etc
var greet = new jet.Method('greet');
greet.on('call', function(who) {
  console.log('Hello', who);


// provide documents/realtime-status/configuration/etc
var jim = new jet.State('persons/#123', getPerson('#123'));
jim.on('set', function(changedPerson) {
  setPerson('#123', changedPerson);
  // changes are propageted automatically


// provide read-only stuff
var nowState = new jet.State('time/now', new Date().getTime());


// change async
setInterval(function() {
  nowState.value(new Date().getTime());
}, 100);

Consume Content:

// fetch/query content
var youngestPersons = new jet.Fetcher()
  .path('startsWith', 'persons/')
  .sortByKey('age', 'number')
  .range(1, 20)
  .on('data', function(persons) {


// call methods'greet', ['Steve']).then(function(response) {

// set states
peer.set('person/#123', {name: 'Jose', age: 33});


Read the Todo-App Tutorial (Vanilla JS client) or the React + Redux Variant for building this simple collaborative realtime app:

Jet Todo-App



$ npm install node-jet

script tag

<script src=""></script>

Stand-Alone Daemon

The package provides a stand-alone Jet Daemon which listens on ports 11122 (trivial protocol) and 11123 (WebSockets) per default.

Start it like this (globally):

 $ jetd.js

Or - if installed locally:

 $ node_modules/.bin/jetd.js

Integrated Daemon

If you want the Jet Daemon to listen for WebSockets on the same port as your existing (node.js) HTTP server, use the daemon.listen({server:httpServer}) method like this:

var httpServer = http.createServer(function(req, res) {
  // serve your stuff

var daemon = new jet.Daemon();
  server: httpServer


Open Radar on, which allows you to see/observe Your Jet States and Methods. Your local Jet Daemon's default WebSocket address is ws://localhost:11123.


For further info and documentation refer to the Jet Homepage.


There is also the canonical ToDo-App available:

You can’t perform that action at this time.