Skip to content

Commit

Permalink
Add to 'supported' API example (so it does something with the result) (
Browse files Browse the repository at this point in the history
…#9989)

* add to example so it does something with the result

* use multi-line code formatting

* add closing }

Co-authored-by: Heather Stenson <heather.stenson@mapbox.com>
  • Loading branch information
Dom Brassey and HeyStenson authored Sep 22, 2020
1 parent f2117b4 commit 6b8c80d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,10 @@ Debug.extend(exported, {isSafari, getPerformanceMetrics: PerformanceUtils.getPer
* be dramatically worse than expected (e.g. a software WebGL renderer would be used).
* @return {boolean}
* @example
* mapboxgl.supported() // = true
* // Show an alert if the browser does not support Mapbox GL
* if (!mapboxgl.supported()) {
* alert('Your browser does not support Mapbox GL');
* }
* @see [Check for browser support](https://www.mapbox.com/mapbox-gl-js/example/check-for-support/)
*/

Expand Down

0 comments on commit 6b8c80d

Please sign in to comment.