title: jQuery Mobile wait until page list-view loads
body: <p>I'm currently developing a small JQM + PhoneGap app (new at this) and got the following issue, I'm loading data from a JSON (which is local, no AJAX yet) to a list-view, the problem comes when I load the  page the css of the list-view takes a little time to load and you can see the bulleted list for a half of a second. Here is a portion of the code which I think is involved </p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;div data-role="content" id="job_offers_close_to_user_result"&gt;
      &lt;!-- Insert job offers from JSON script here --&gt;
      &lt;div id="fill_with_job_offers_close_to_user_result"&gt;&lt;/div&gt;
      &lt;div id="view_job_offer_button"&gt;&lt;/div&gt;
  &lt;/div&gt;
  </code></pre>
  
  <pre class="lang-js prettyprint-override"><code>AppController.fillJobsList = function(){
  $("#view_job_offer_button").append(" ");
  $("#fill_with_job_offers_close_to_user_result").html(" ");
  for (var i=0; i &lt; JSON_with_jobs.ofertas.length; i++){
      $("#fill_with_job_offers_close_to_user_result").append("&lt;ul data-role='listview'&gt;"
          + "&lt;li&gt;&lt;a href='#job_description_"+i+"'&gt;"
          + JSON_with_jobs.ofertas[i].titulo + "&lt;br /&gt;"
          + JSON_with_jobs.ofertas[i].empresa + "&lt;br /&gt;"
          + JSON_with_jobs.ofertas[i].contrato + "&lt;br /&gt;"
          + JSON_with_jobs.ofertas[i].localidad + "," + JSON_with_jobs.ofertas[i].provincia + "&lt;br /&gt;"
          + "&lt;br /&gt;"
          +"&lt;/a&gt;&lt;/li&gt;"
          + "&lt;/ul&gt;"
  );
  </code></pre>
  
  <p>This function is triggered when clicked a button</p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;a id="mybutton2" onclick="AppController.fillJobsList()" href="#close_to_user" data-role="button"&gt;Buscar&lt;/a&gt;
  </code></pre>
  
  <p>Thanks in advance!</p>