womap
TypeScript icon, indicating that this package has built-in type declarations

0.1.11 • Public • Published

WoMap

Map based on leaflet and mapbox vector tiles. Icons are displayed using PixiJS. The service is provided by WO.

How to use

  • Run npm i womap

  • Add leaflet styles angular.json (more info)

 {
  ...
  "styles": [
    "styles.css",
    "./node_modules/leaflet/dist/leaflet.css"
  ],
  ...
}
  • Add assets in your angular.json
{
  ...
  "assets": [
    "src/assets",
    {
      "glob": "**/*",
      "input": "./node_modules/womap/assets",
      "output": "assets/"
    }
  ],
  ...
}
  • Add mapbox styles to your index.html
<link href="https://api.tiles.mapbox.com/mapbox-gl-js/v1.4.0/mapbox-gl.css" rel="stylesheet"/>
  • Use the lib-womap your component
<div>
  <lib-womap accessToken="05f60c8d-5427-42fb-8ee5-01adbed78d42"></lib-womap>
</div>
  • For socket.io to work, add the next line to polyfills.ts file in your src directory.

(window as any).global = window

Dependencies (11)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i womap

    Weekly Downloads

    2

    Version

    0.1.11

    License

    none

    Unpacked Size

    1.06 MB

    Total Files

    109

    Last publish

    Collaborators

    • amustelier