This package has been deprecated

Author message:

WARNING: We renamed this module to @webex/common-evented. Please install it instead. See https://github.com/webex/spark-js-sdk#the-cisco-webex-js-sdk for more information.

@ciscospark/common-evented

1.52.2 • Public • Published

@ciscospark/common-evented

standard-readme compliant

Class property decorator the adds change events to properties

Install

npm install --save @ciscospark/common-evented

Usage

const evented = require(`@ciscospark/common-evented`);
const Events = require(`ampersand-events`);

class X extends Events {
  @evented
  prop = null
}

const x = new X();
x.on(`change:prop`, () => {
  console.log(x.prop)
  // => 6
});
x.prop = 6;

Maintainers

This package is maintained by Cisco Webex for Developers.

Contribute

Pull requests welcome. Please see CONTRIBUTING.md for more details.

License

© 2016-2018 Cisco and/or its affiliates. All Rights Reserved.

Readme

Keywords

none

Package Sidebar

Install

npm i @ciscospark/common-evented

Weekly Downloads

56

Version

1.52.2

License

MIT

Unpacked Size

7.5 kB

Total Files

6

Last publish

Collaborators

  • webex-jenkins
  • adamweeks