MapBox加载不同风格的地图

初始化MapBox地图:

	var map = new mapboxgl.Map({
          container: 'map',
          zoom: 3,
          center: [105, 34],
          
		  //此处更改地图风格
          style: 'mapbox://styles/mapbox/satellite-v9',
          hash: false,
      });

1.户外地图(mapbox://styles/mapbox/basic-v9)新版:(mapbox://styles/mapbox/outdoors-v12)支持三维地图

2.街道地图(mapbox://styles/mapbox/streets-v9) 新版:(mapbox://styles/mapbox/streets-v12)支持三维地图

3.浅色地图(mapbox://styles/mapbox/light-v9) 新版:(mapbox://styles/mapbox/light-v11)支持三维地图
MapBox加载不同风格的地图_第1张图片
4.深色地图(mapbox://styles/mapbox/dark-v9) 新版:(mapbox://styles/mapbox/dark-v11)支持三维地图
MapBox加载不同风格的地图_第2张图片
5.鲜艳地图(mapbox://styles/mapbox/bright-v9)

6.影像地图(mapbox://styles/mapbox/satellite-v9)

7.导航地图+实时交通路况+白天(mapbox://styles/mapbox/navigation-preview-day-v2)

8.导航地图+实时交通路况+夜晚(mapbox://styles/mapbox/navigation-preview-night-v2)

9.导航地图+白天
(mapbox://styles/mapbox/navigation-guidance-day-v2)

10.导航地图+夜晚
(mapbox://styles/mapbox/navigation-guidance-night-v2)

你可能感兴趣的:(MapBox,前端,javascript,开发语言)