Documented Evented differences from Node.js events

events
Mike Gerwitz 2014-08-03 00:59:07 -04:00
parent e55288c989
commit bac61c3f08
1 changed files with 10 additions and 1 deletions

View File

@ -36,7 +36,16 @@ var Trait = require( 'easejs' ).Trait,
* listeners.
*
* The API is motivated by (and is a replacement for) Node.js' event emitter
* implementation, but is more robust.
* implementation, but is more robust. Note, however, that it differs
* significantly in a number of implementation details:
*
* - All events must be pre-registered, and all listeners must hook a
* registered event;
* - The same listener cannot be attached to the same event multiple
* times (will produce an exception);
* - There is no special `error' event that will, if unhooked, trigger an
* exception when emitted; and
* - It is implemented as a trait.
*/
module.exports = Trait( 'Evented',
{