Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
minimal yet very useful synchronization primitive on top of jQuery Deferreds
JavaScript
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
build
doc
src
use-case
.gitignore
LICENSE
README.md
index.js
package.json

README.md

Fence

A minimal yet very useful synchronization primitive on top of jQuery Deferreds that is available as a jQuery plugin client-side and a npm package for node server-side.

Latest version of Fence is version 0.4.0

What is it?

See our Introduction to Fence.

Installation

Server-Side: Node

  • use npm: npm install fence
  • or put fence as a dependency in package.json

Fence itself depends on JQDeferred an automated port of jQuery Deferreds to node.

Once Fence is installed, require it in your code:

var Fence = require( "fence" );

Client-Side

Download the minified or full-text version of the plugin and drop it into your project.

Then:

  • put a script tag to load the plugin in your html: <script src="path/to/js/fence.0.4.0.js"></script>
  • OR use your favorite script loader: yepnope( "path/to/js/fence.0.4.0.js" );

After that, Fence is available as jQuery.Fence, that simple.

Build Fence

To build Fence yourself, you need node.

  1. clone the repository: git clone git://github.com/jaubourg/fence.git
  2. enter the newly created directory: cd fence
  3. checkout the version you want to build: git checkout 0.4.0
  4. install node dependencies: npm install
  5. launch the builder: node .

Node package is now located in dist/node, jQuery plugin in dist/jquery.

Something went wrong with that request. Please try again.