UNPKG

trackasia-gl

Version:

BSD licensed community fork of mapbox-gl, a WebGL interactive maps library

62 lines (40 loc) 2.45 kB
<p align="center"> <img src="https://static.track-asia.com/logo.svg" alt="TrackAsia Logo"> </p> # TrackAsia GL JS [![License](https://img.shields.io/badge/License-BSD_3--Clause-blue.svg?style=flat)](LICENSE.txt) [![Version](https://img.shields.io/npm/v/trackasia-gl?style=flat)](https://www.npmjs.com/package/trackasia-gl) [![CI](https://github.com/track-asia/trackasia-gl-js/actions/workflows/test-all.yml/badge.svg)](https://github.com/track-asia/trackasia-gl-js/actions/workflows/test-all.yml) [![PRs](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat)](https://opensource.org/licenses/BSD-3-Clause) **[TrackAsia GL JS](https://docs.track-asia.com/)** is an open-source library for publishing maps on websites or webview apps. It renders vector tiles using GPU/WebGL for fast, interactive maps. This project is a community fork of [mapbox-gl-js](https://github.com/mapbox/mapbox-gl-js) before it switched to a non-OSS license. Early versions (1.x) are compatible with Mapbox OSS, but the project has since evolved independently. ## Quickstart Add the JavaScript and CSS files to your `<head>`: ```html <script src='https://unpkg.com/trackasia-gl@latest/dist/trackasia-gl.js'></script> <link href='https://unpkg.com/trackasia-gl@latest/dist/trackasia-gl.css' rel='stylesheet' /> ``` In your `<body>`: ```html <div id='map' style='width: 400px; height: 300px;'></div> <script> var map = new trackasiagl.Map({ container: 'map', style: 'https://maps.track-asia.com/styles/v1/streets.json?key=public_key', center: [105.85, 21.03], zoom: 10 }); </script> ``` ## Documentation Full documentation at [https://docs.track-asia.com/](https://docs.track-asia.com/) Examples: | Showcases | | | ---- | ---- | |![Display a map](https://static.track-asia.com/examples/simple-map.png) |![3D buildings](https://static.track-asia.com/examples/3d-buildings.png) | |![Animate a series of images](https://static.track-asia.com/examples/animate-images.png) |![Create a heatmap layer](https://static.track-asia.com/examples/heatmap-layer.png) | ## Contributing See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines. ## Sponsors TrackAsia is developed by the community and organizations that provide financial support. ## Thanks to Mapbox 🙏🏽 TrackAsia GL JS is based on the open-source foundation of Mapbox GL JS 1.x. ## License **TrackAsia GL JS** is released under the [BSD 3-Clause](./LICENSE.txt) license.