title: How to inject a service as dependency for a custom filter in angular.js?
body: <p>I am trying to create a custom filter to track events. So the filter can call methods on the segmentio service. </p>
  
  <pre><code>angular.module('sageApp')
    .filter('trackEvent', function(segmentio) {
      return function(entry, category) {
       segmentio.track(entry, category);
      }
  });
  </code></pre>
  
  <p>But the segmentio service is not available. Any ideas on how to dependency inject a service to a filter woule be much appreciated.</p>