title: How can I populate a select dropdown list from a JSON feed with AngularJS?
body: <p>I have been looking hard for examples but could not find anything at all. The only thing I know is that I could use the http module to get my data. Here is what I am currently doing, but it's coded with Knockout. Can someone give me some advice on how I could recode this feature using AngularJS?</p>
  
  <p>HTML</p>
  
  <pre><code>&lt;select id="testAccounts" 
     data-bind="options: testAccounts, optionsValue: 'Id', optionsText: 'Name', optionsCaption: 'Select Account', value: selectedTestAccount"&gt;
  &lt;/select&gt;
  </code></pre>
  
  <p>Javascript</p>
  
  <pre><code>&lt;script type='text/javascript'&gt;
      $(document).ready(function () {
  
          var townSelect = function () {
          var self = this;
          self.selectedTestAccount = ko.observable();
          self.testAccounts = ko.observableArray();
          var townViewModel = new townSelect();
          ko.applyBindings(townViewModel);
  
          $.ajax({
              url: '/Admin/GetTestAccounts',
              data: { applicationId: 3 },
              type: 'GET',
              success: function (data) {
                  townViewModel.testAccounts(data);
              }
          });
      });
  &lt;/script&gt;
  </code></pre>