Sha256: 61aeb51f413b58f2ec8490891a983cf6e72db6c7292ce33678e2a6bd5f5cacec

Contents?: true

Size: 969 Bytes

Versions: 15

Compression:

Stored size: 969 Bytes

Contents

exports.adapter =
  subscribe: (record, attribute_path, callback) ->
    throw new TypeError 'observable.adapters.rivets.subscribe: No record provided for subscription' unless record?
    # TODO parse aura widget attributes options, remove, add as a
    # comentary, and let rivets bindings flow, and remove the if check
    record.subscribe attribute_path, callback if attribute_path
  unsubscribe: (record, attribute_path, callback) ->
    throw new TypeError 'observable.adapters.rivets.unsubscribe: No record provided for subscription' unless record?
    record.unsubscribe attribute_path, callback
  read: (record, attribute_path) ->
    throw new TypeError 'observable.adapters.rivets.read: No record provided for subscription' unless record?
    record[attribute_path]
  publish: (record, attribute_path, value) ->
    throw new TypeError 'observable.adapters.rivets.publish: No record provided for subscription' unless record?
    record[attribute_path] = value

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
ende-0.4.25 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.24 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.23 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.22 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.21 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.15 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.14 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.13 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.12 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.11 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.10 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.9 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.8 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.7 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee
ende-0.4.6 vendor/components/indefinido-observable/src/lib/adapters/rivets.js.coffee