Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 079895c2d2
Fetching contributors…

Cannot retrieve contributors at this time

57 lines (42 sloc) 1.68 kb


Lace is a control flow library that doesn't get in your way. Here's how it works

// Require the lib
var lace = require('lace');

// Call lace. Create a lacing (series of functions).
    // Within each of these functions are some helpers contained in the lace global.; // This calls the next function in the series.
}) // Lace supports currying to create the lacing.
    // Helpers are also available here.
    // All arguments are directly from the invocation of the previous (no appending or prepending of arguments).
    // The `this` context will be what the context of's context was applied to.

    // Inner lacings are supported
        // Helpers will work reference the inner lacing;
        // Access to the outer lace is done through the lace.outer helper property;
    // This was called from the
    // Everything should just work, without getting in your way.

Lace is all about asynchronous control flow. You can pass to asynchronous function such as setTimout, database query callbacks, etc.

Another thing to keep in mind, is that the first function is called asynchronously:

console.log('Called before initial lacing function.');

    console.log('Initial lacing funciton.');

console.log('Also, called before initial lacing function.')



Library name. Global exported object and helper.


The lacing is the series of functions or function sets. A lacing function is one of the "steps" in the control flow.

Jump to Line
Something went wrong with that request. Please try again.