title: in reflux, how can i get data from asp.net web api
body: <p>i'am using reflux of reactjs. From  Store's action of reflux, i wrote a action to get data from asp.net web api, i think that just only way to get data which use to ajax, someone say with me, i can get data with a plugin jquery but i don't believe it because the $.ajax is best way. I search everything on google but i don't see to resolve for that. If you know something to resolve, please share with me, i really thanks.</p>
  
  <p>Beside, i had a problem with global and local variable of ajax. Please review my code, you can see the bold text which never return a value, the problem which stay with the block of success, the list var isn't update when it outside of the block. What's up problem with that ? how can i fix that error ?</p>
  
  <p>Thank you very much, again!</p>
  
  <pre><code>(function (Reflux, WorkHistoryActions, global) {
  
      global.workhistoryStore = Reflux.createStore({
  
          listenables: [WorkHistoryActions],
  
          init: function () {
              this.storyArr = [];
          },
  
          getItems: function (resume_id) {
              console.log(resume_id)
              **var list = [];**
              $.ajax({
                  type: "get",
                  url: global.getHost() + "/api/workhistories/6969607988340821009",
                  dataType: 'json',
                  crossDomain: true,
                  success: function (data) {
  
                      $.each(data, function (i, v) {
                          **list.push(v);**
                      })
  
                  }
              });
              **return list;**
          },
  })
  </code></pre>