Move mapboxgl.supported logic into standalone module
Presently, end users are required to include all of mapbox-gl.js in order to test if it is supported. This is impractical for bandwidth-conscious users who are implementing fallback to mapbox.js.
:+1:
This would greatly improve the experience for Android devices that don't support WebGL. We could use this to only download the GL or raster code and not double up. Critical for 2G/3G networks.
Agreed, I'd love to see a solution for this.
I have moved the necessary logic to https://github.com/mapbox/mapbox-gl-js-supported
Next Steps
- [x] have another engineer review https://github.com/mapbox/mapbox-gl-js-supported
- [x] publish the new module to npm
- [x] use the new module within Mapbox GL JS
- [x] move any relevant issues from this repo to the new repo
@bhousel Does this look ready to 🚢?