You're Invited:Meet the Socket Team at BlackHat and DEF CON in Las Vegas, Aug 4-6.RSVP
Socket
Book a DemoInstallSign in
Socket

@deck.gl/geo-layers

Package Overview
Dependencies
Maintainers
5
Versions
425
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@deck.gl/geo-layers

deck.gl layers supporting geospatial use cases and GIS formats

9.1.14
latest
Source
npmnpm
Version published
Weekly downloads
219K
-2.82%
Maintainers
5
Weekly downloads
 
Created

What is @deck.gl/geo-layers?

@deck.gl/geo-layers is a collection of layers for geospatial visualization built on top of deck.gl. It provides specialized layers for rendering geospatial data, such as polygons, paths, and points, with support for various data formats and sources.

What are @deck.gl/geo-layers's main functionalities?

H3HexagonLayer

The H3HexagonLayer is used to visualize data aggregated into hexagonal grids using the H3 spatial indexing system. This example demonstrates how to create a hexagon layer with elevation and color based on data values.

const {DeckGL} = require('@deck.gl/react');
const {H3HexagonLayer} = require('@deck.gl/geo-layers');

const layer = new H3HexagonLayer({
  id: 'h3-hexagon-layer',
  data: 'https://raw.githubusercontent.com/uber-common/deck.gl-data/master/website/sf.h3cells.json',
  pickable: true,
  extruded: true,
  elevationScale: 1000,
  getHexagon: d => d.hexagon,
  getFillColor: d => [255, (1 - d.count / 5000) * 255, 0],
  getElevation: d => d.count
});

const deckgl = new DeckGL({
  initialViewState: {
    longitude: -122.4,
    latitude: 37.74,
    zoom: 11,
    pitch: 30,
    bearing: 0
  },
  controller: true,
  layers: [layer]
});

TileLayer

The TileLayer is used to render raster tiles from a tile server. This example demonstrates how to create a tile layer using OpenStreetMap tiles.

const {DeckGL} = require('@deck.gl/react');
const {TileLayer} = require('@deck.gl/geo-layers');

const layer = new TileLayer({
  data: 'https://c.tile.openstreetmap.org/{z}/{x}/{y}.png',
  minZoom: 0,
  maxZoom: 19,
  tileSize: 256,
  renderSubLayers: props => {
    const {tile} = props;
    return new BitmapLayer(props, {
      data: null,
      image: tile.data,
      bounds: tile.bbox
    });
  }
});

const deckgl = new DeckGL({
  initialViewState: {
    longitude: -122.4,
    latitude: 37.74,
    zoom: 11,
    pitch: 30,
    bearing: 0
  },
  controller: true,
  layers: [layer]
});

TripsLayer

The TripsLayer is used to visualize vehicle trips along a path over time. This example demonstrates how to create a trips layer with animated paths.

const {DeckGL} = require('@deck.gl/react');
const {TripsLayer} = require('@deck.gl/geo-layers');

const layer = new TripsLayer({
  id: 'trips-layer',
  data: 'https://raw.githubusercontent.com/uber-common/deck.gl-data/master/examples/trips/trips-v7.json',
  getPath: d => d.path,
  getTimestamps: d => d.timestamps,
  getColor: [253, 128, 93],
  opacity: 0.8,
  widthMinPixels: 2,
  rounded: true,
  trailLength: 180,
  currentTime: 100
});

const deckgl = new DeckGL({
  initialViewState: {
    longitude: -122.4,
    latitude: 37.74,
    zoom: 11,
    pitch: 30,
    bearing: 0
  },
  controller: true,
  layers: [layer]
});

Other packages similar to @deck.gl/geo-layers

Keywords

webgl

FAQs

Package last updated on 28 Jul 2025

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.