# mapbox-gl-framerate **Repository Path**: mirrors_mapbox/mapbox-gl-framerate ## Basic Information - **Project Name**: mapbox-gl-framerate - **Description**: A frame rate control to evaluate map rendering performance - **Primary Language**: Unknown - **License**: ISC - **Default Branch**: publisher-production - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2020-08-09 - **Last Updated**: 2026-01-03 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README mapbox-gl-framerate ([demo](https://labs.mapbox.com/mapbox-gl-framerate/)) --- A frame rate control to evaluate map rendering performance ### Usage ```js const map = new mapboxgl.Map({ container: 'map', style: 'mapbox://styles/mapbox/light-v9' }); const fps = new mapboxgl.FrameRateControl({ /* optional options */ }); map.addControl(fps); ``` ### Options | Property | Value | Description | | ---- | ---- | ---- | | background |
rgba(0,0,0,0.9)
| Color of the background container. | | barWidth |
4 * window.devicePixelRatio
| Width of each individual performance bar. | | color |
#7cf859
| Bar & text color. | | font |
'Monaco, Consolas, Courier, monospace'
| Comma separated string of fonts for text. | | graphHeight |
60 * window.devicePixelRatio
| Graph height. | | graphWidth |
90 * window.devicePixelRatio
| Graph width. | | graphTop |
0
| Top position of the graph. | | graphRight |
5 * window.devicePixelRatio
| Right position of the graph. | | width |
100 * window.devicePixelRatio
| Container width of the graph. | ### Running the demo ```sh npm install & npm start & open http://localhost:1337/ ```