kd-rope

    0.0.1 • Public • Published

    Koding Kite to Kite Require Wrapper

    Rope is the require wrapper for kites. It simply wraps with Proxy.

    Getting Started

    First install koding rope from npm.

    npm install kd-rope

    You should require kd-rope in kite file.

    rope = require "kd-rope"
     
    # kite instance... 
     
    mykite = rope kiteInstance"mykite"
     
    mykite.kiteMethod{params: true}(err, response)->
      # bla bla 

    Kite Example

    Kite = require 'kd-kite'
    rope = require 'kd-rope'
    manifest = require './manifest'
     
    kite = new Kite manifest,
         pingKite: (options, callback) ->
     
         # anotherKite = rope kite, 'anotherKite' 
     
         # anotherKite.pingKite {param: true}, (err, result)-> 
         #   callback null, result 
     
         return callback null"pong from #{name}"
     
    module.exports = kite

    It uses proxies to wrap the kites.

    mykite = rope kite'mykite'
     
    mykite.pingKite {}(err, result)->
      callback nullresult

    Install

    npm i kd-rope

    Homepage

    koding.com

    DownloadsWeekly Downloads

    0

    Version

    0.0.1

    License

    none

    Last publish

    Collaborators

    • mgg