event.js

0.1.0 • Public • Published

event.js V0.1.0

a async & UI-non-blocking event-customable frontend library

it can create JavaScript Obejcts obtain HTMLElement's feature---Event Driven

all the events' workflow is providen by DOM Event Model

Notice!

This module is only available in the web browser!

install:
npm install event.js
example:
  var spore = new EventEmitter();

  spore.on('growup', function (data) {
    console.log(data);
  });

  spore.on('die', function (data) {
    // ...
  });

  spore.emit('born', { size: 0.05, color: blue });
other usages && options:
  EventEmitter(options)

  the options is an object, all the events follow this setting:
  {
    MAXListener: <Number>,
    bubbles: <Boolean>,
    cancelable: <Boolean>
  }

  method:
    .emit()
    .on()
    .once()
    .removeListener()

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.1.0
    70
    • latest
  • 0.0.4
    0
    • 0.0.4

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.1.0
    70
  • 0.0.6
    0
  • 0.0.5
    0
  • 0.0.4
    0
  • 0.0.3
    0

Package Sidebar

Install

npm i event.js

Weekly Downloads

35

Version

0.1.0

License

MIT

Last publish

Collaborators

  • soufii