capirona

0.2.0 • Public • Published

Javascript Tasks

Example task:

var capirona = require("capirona");
 
capirona.make({
    "def hello/:name": {
        "run": function(target, next) {
            console.log("hello %s!", target.data.name);
            next();
        }
    }
}).run("hello/craig", function() {
    console.log("done");
});

API

.make(task)

creates a new runnable script

.run(command, target, callback)

runs the given task. The target can be any value. For example:

 
capirona.make({
        "def log": {
                "run": function(target, next) {
                        console.log(target.value || target.data.text);
                        next();
                }
        }
}).
run("log", "hello world!").
run("log", {
    text: "hello world!"
});

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.2.0
    4
    • latest

Version History

Package Sidebar

Install

npm i capirona

Weekly Downloads

48

Version

0.2.0

License

none

Last publish

Collaborators

  • architectd
  • crcn