title: Openlayers 3.5 and GeoJSON
body: <p>I'm having a problem with OpenLayers 3.5. I'm trying to use the one-off loading strategy to grab features from a GeoJSON file. I'm adding a new layer to an already instantiated map. My code looks like this:</p>
  
  <pre class="lang-js prettyprint-override"><code>var vectorSource = new ol.source.Vector({
    url: layerInfo.url,
    format: new ol.format.GeoJSON()
  });
  
  var pointsLayer = new ol.layer.Vector({
    source: vectorSource,
    style: styleFunc
  });
  
  that.map.addLayer(pointsLayer);
  pointsLayer.setVisible(true);
  </code></pre>
  
  <p>However, nothing shows, and when I examine <code>pointsLayer.getSource().getFeatures()</code>, I discover that no features were actually loaded.</p>
  
  <p>So, now I tried to load the features a different way:</p>
  
  <pre class="lang-js prettyprint-override"><code>var that = this;
  
  $.get(layerInfo.url, function(response) {
  
    var vectorSource = new ol.source.Vector({
      features: (new ol.format.GeoJSON()).readFeatures(response)
    });
  
    var pointsLayer = new ol.layer.Vector({
      source: vectorSource,
      style: styleFunc
    });
  
    that.map.addLayer(pointsLayer);
    pointsLayer.setVisible(true);
  });
  </code></pre>
  
  <p>This DOES work. I'm banging my head against a wall here. Does anyone have any ideas? Thanks so much!</p>