title: Extend ng-if or implement similar directive
body: <p>I would like to include or exclude content based on a boolean value.
  The boolean value comes from a service that provides feature toggles.  I don't want to inject the directive in a lot of places or use <code>$root</code> in a condition for <code>ng-if</code>.</p>
  
  <p>So I would like to create an AngularJS attribute directive that is similar to <code>ng-if</code> but has the service injected and includes/excludes the content based on the boolean value, instead of getting a condition expression from the attribute value in the template.</p>
  
  <p>Is it possible to somehow extend the existing <code>ng-if</code> directive?  If not, what would be the easiest/best way to implement similar behavior?</p>