I'm trying to build a logging system for events on a number of various $resource
. I have a factory that I've built that does exactly what I would like, however, I don't want to pollute my controllers with unnecessary code, i'd like to get the logger factory to trigger every time a resource is triggered (being able to customize the data being sent to the factory).
I can't seem to find a way to do this through the various methods on the $resource
.
Any ideas or suggestions for solving this type of problem? Am I overcomplicating it?