title: Set ng-click attribute value from a string variable
body: <p>I have an external JSON file which is a collection of buttons/actions like this</p>
  
  <pre><code>   {  
     "foo1":{  
        "name":"productDetails",
        "displayAs":"button",
        "action":"viewDetails()"
     },
     "foo2":{  
        "name":"sell",
        "displayAs":"button",
        "action":"sellProduct()"
     }
  }
  </code></pre>
  
  <p>Later, in my view, I create a <code>&lt;div&gt;</code> using ng-repeat for each object contained in that JSON. </p>
  
  <p>My question is, can I set the ng-click property as it it in the JSON file like this?</p>
  
  <pre><code>&lt;li ng-repeat = "field in fields"&gt;
      &lt;div ng-click = field.action &gt; {{field.name}} &lt;/div&gt;
  &lt;/li&gt;
  </code></pre>