0.0.11 • Published 8 years ago

rijs.helpers v0.0.11

Weekly downloads
8
License
pemrouz.mit-licen...
Repository
github
Last release
8 years ago

Ripple | Helpers

Coverage Status Build Status

Allows registering helper functions for a resource.

export default {
  name: 'foo'
, body: { bar: 1 }  
, headers: { helpers: { help, constant: 5 } }
}

function help(){ return 'help!' }

You will be able to access the helper functions from the resource itself, on the server or client, even if you overwrite the entire resource body:

ripple('foo').help()   // 'help!'
ripple('foo').constant // 5

ripple('foo', { bar: 2 })

ripple('foo').help()   // 'help!'
ripple('foo').constant // 5
0.0.11

8 years ago

0.0.10

8 years ago

0.0.9

8 years ago

0.0.8

8 years ago

0.0.7

8 years ago

0.0.6

8 years ago

0.0.5

8 years ago

0.0.4

9 years ago

0.0.3

9 years ago

0.0.2

9 years ago

0.0.1

9 years ago