Skip to content

Event system #117

Closed
Closed
@jmdobry

Description

@jmdobry

What about adding an event system to angular-data, such that whenever angular-data does anything it broadcasts the result of the action on $rootScope. This would provide an avenue for asynchronously reacting to changes within the datastore. Example:

DS.find('user', 5);

Somewhere else:

$rootScope.$on('DS.inject', function ($event, resourceName, injected) {
   /// do something in response
});

@kentcdodds @kenborge Thoughts?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions