mapbox/mapbox-gl-js

Cache-defeating URL parameters aren't passed to sprite URLs

Open

#5550 aperta il 30 ott 2017

Vedi su GitHub
 (0 commenti) (5 reazioni) (0 assegnatari)JavaScript (2203 fork)batch import
bug :lady_beetle:good first issue

Metriche repository

Star
 (10.532 star)
Metriche merge PR
 (Nessuna PR mergiata in 30 g)

Descrizione

mapbox-gl-js version: 0.41.0

Steps to Trigger Behavior

  1. Call mapboxgl.map({ ... style: 'mapbox://styles/user/abc123?update=1 } )
  2. The style file is fetched from: api.mapbox.com/styles/v1/user/abc123.json?update=1&access_token=...

Expected Behavior

  1. The sprite file is fetched from api.mapbox.com/styles/v1/user/abc123/sprite@2x.json?update=1&access_token=...

Actual Behavior

  1. The sprite file is fetched from api.mapbox.com/styles/v1/user/abc123/sprite@2x.json?access_token=...

This means that when you update icons through the Studio interface, it often takes a long time before you can see them in your maps, because the files get cached along the way, and there's really no workaround.

Guida contributor