Socket
Socket
Sign inDemoInstall

leaflet-stream

Package Overview
Dependencies
13
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    leaflet-stream

Pipe geojson into a map


Version published
Weekly downloads
2
increased by100%
Maintainers
1
Created
Weekly downloads
 

Readme

Source

leaflet-stream

NPM

Install with npm install leaflet-stream.

Pipe geojson objects into a leaflet map object. Every object will be on their own layer and geojson properties will be converted to popups.

var leafletstream = require('leaflet-stream')

var stream = leafletstream(map)

stream.write({
    "type": "Feature",
    "properties": {
      "name": "Eiffel Tower",
      "description": "The Eiffel Tower is an iron lattice tower located on the Champ de Mars in Paris.",
      "rating": 4.7,
      "height": "301m"
    },
    "geometry": {
        "type": "Point",
        "coordinates": [2.294481,48.85837]
    }
})

stream.end()

Eiffel Tower

This module is similar to and inspired by leaflet-geojson-stream

Keywords

FAQs

Last updated on 25 Feb 2015

Did you know?

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

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc