title: fetch data from rest api and display to the dropdown on UI using Oracle JET
body: <p>trying to get data in drop-down from the rest api response </p>
  
  <pre><code>var self = this;
    $(document).ready(
              function()
              {
                   val = [];
                  alert('test');
                  restApiFactory.getReleases().fetch({
              success:function(model,response){
                  console.log(response);
                  this.val = ko.observableArray(response['uri']);
                  //self.books(response);
                  function ValueModel() {
      this.val = ko.observableArray();
    }
    ko.applyBindings(new ValueModel(), document.getElementById('form1'));
              }
          })
                  //console.log(self.books());
                //ko.applyBindings(null, document.getElementById('form-container'));
              }
          );
  define(['ojs/ojcore','ojs/ojmodel'],function(oj){
  
  var apiFactory = {};
  apiFactory.baseUrl = 'restapi.get.url';
  apiFactory.getReleases = function(){
      var Book = oj.Model.extend({
         url: apiFactory.baseUrl,
         idAttribute:'page'
      });
      return new Book();
  }
  return apiFactory;
  </code></pre>
  
  <p>});</p>
  
  <p>getting error :
  Uncaught (in promise) ReferenceError: Unable to process binding "ojComponent: {component:'ojSelect',value:val,rootAttributes:{style:'max-width:20em'}}"
  Message: val is not defined</p>