Switch branches/tags
Nothing to show
Find file History
Pull request Compare This branch is 23 commits behind addyosmani:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.



A common demo application for popular JavaScript MV* frameworks


This demo was written to illustrate how a server-side JavaScript solution could be applied to the TodosMVC application using sockets.

Technologies Used In This Demo

  • Underscore.js - A utility-belt library for JavaScript without extending any of the built-in JavaScript objects.
  • Backbone.js - Gives structure to web applications by providing models with key-value binding and custom events, collections with a rich API of enumerable functions, views with declarative event handling, and connects it all to your existing API over a RESTful JSON interface.
  • backbone.iobind - Bind socket.io events to backbone models & collections. Also includes a drop-in replacement for Backbone.sync using socket.io.
  • jQuery - A fast, concise, library that simplifies how to traverse HTML documents, handle events, perform animations, and add AJAX.
  • Node.js - Event-driven I/O server-side JavaScript environment based on V8.
  • Express - High performance, high class web development for node.js.
  • Jade - High performance template engine heavily influenced by Haml and implemented with JavaScript for node.js.
  • Stylus - Expressive, dynamic, robust CSS for node.js
  • Socket.io - Aims to make realtime apps possible in every browser and mobile device, blurring the differences between the different transport mechanisms. It's care-free realtime 100% in JavaScript.
  • Mongoose - A MongoDB object modeling tool designed to work in an asynchronous environment.
  • MongoDB - A scalable, high-performance, open source NoSQL database.
  • Redis - an open source, advanced key-value store. It is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets.

Getting the Demo

  1. Fork this repo by clicking the "Fork" button above
  2. Clone your fork to make a local working copy. For example:
$ git clone git@github.com:[your_github_username]/backbone-boilerplates.git
$ cd backbone-boilerplates/option7_node_socketio

Setting up Dependencies

  1. Install node.js.
  2. Install MongoDB.
  3. Start the MongoDB server from a terminal window:
$ mongod
  1. Install Redis.
  2. Start the Redis Server from another terminal window:
$ redis-server
  1. Make sure your current directory is option7_node_socketio before step 7.
$ pwd
[your repos path]/backbone-boilerplates/option7_node_socketio
  1. Install dependencies using the node package manger (npm).
$ sudo npm link

Running the Demo

  1. Start the Todos demo server from a different terminal window:
$ node app
  1. Visit http://localhost:3000 in a web browser.



Public Domain