Closed timelf123 closed 8 years ago
Keeping to the standard set before, if an event has an action, that is the name of the event. You can also pass a string as the name
action
Action
Articles.events.publish({ action: 'article:deleted', user: { name: req.user.name }, name: article.title });
String
Articles.events.publish('article:deleted');
Subscribing: PackageName.events.subscribe('article:deleted', function(){console.log('event fired')});
PackageName.events.subscribe('article:deleted', function(){console.log('event fired')});
Fixes #96
Submitting against https://github.com/linnovate/meanio/tree/0.9.0 instead
Keeping to the standard set before, if an event has an
action
, that is the name of the event. You can also pass a string as the nameAction
String
Subscribing:
PackageName.events.subscribe('article:deleted', function(){console.log('event fired')});
Fixes #96