title: Optional attribute in directive
body: <p>I have a directive with an isolate scope. Like this:</p>
  
  <pre><code>app.directive('myDirective', function() {
      return {
          restrict: 'E'
          scope: {
              attr1: "=",
              attr2: "@",
              attr3: "&amp;" 
          }, 
          template: 
              &lt;div&gt;
  
                  &lt;button ng-if="{true if attr3 is defined, otherwise false}"/&gt;
  
              &lt;/div&gt;
  
      };
  });
  </code></pre>
  
  <p>One of the attributes - <code>attr3</code>, which is a callback - is optional. What I want to do is if the attribute exists, a button will exist, otherwise, the button is not there. Thanks for your help.</p>