- git clone --branch v1.8.1 https://github.com/mapbox/mapbox-gl-js.git
- cd mapbox-gl-js
- npm install
NOTE) if the installation fails on windows, open a new terminal as adminstrator and run
npm install --global windows-build-tools
- npm i yarn
- to build the js file 'dist/mapbox-gl.js' yarn run build-prod-min
- to build the css file 'dist/mapbox-gl.css' yarn run build-css