Navigation Menu

Skip to content

nomilous/also

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

npm install also

Version 0.0.14 (unstable)

also

An accumulating set of function decorators.

Function decorators?: Coffeescript Ristretto

Examples

synchronous example with fairy tale

Dwarves     = 0
SnowWhites  = 0

{inject} = require 'also'

Hi = Ho = inject.sync

    beforeAll:  -> SnowWhites++
    beforeEach: -> Dwarves++

    -> 

        SnowWhites: SnowWhites, Dwarves: Dwarves



Hi Ho, Hi Ho, Hi Ho Hi Ho, Hi Ho()

# => { SnowWhites: 1, Dwarves: 7 }

synchronous example with node modules

nodeModules = (names) -> require name for name in names 
        
start = inject.sync nodeModules, (crypto, zlib, net) -> 

    #
    # ...
    # 

start()

asynchronous example

none. see spec

todo

  • combine with Notice (hub) and run as daemon (script server for worker/drone farm)

Releases

No releases published

Packages

No packages published