You're Invited: Meet the Socket team at BSidesSF and RSAC - April 27 - May 1.RSVP
Socket
Sign inDemoInstall
Socket

leaflet-weathericonslayer

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

leaflet-weathericonslayer

Current weather icons layer for Leaflet, based on OpenWeatherMap API

0.0.1
latest
Source
npm
Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

Leaflet.WeatherIconsLayer

Current weather icons layer for Leaflet, based on OpenWeatherMap API. Partial rework of outdated sample script from OpenWeatherMap site.

As an OpenWeatherMap derivative work, licenced with Creative Commons BY-SA 2.0. OpenWeatherMap Terms of service apply.

Usage

map.addLayer(new L.WeatherIconsLayer());

Also, several options available. Here are the defaults shown:

map.addLayer(new L.WeatherIconsLayer({
    apiKey: undefined,                  // OpenWeatherMap API key
    host: 'http://openweathermap.org/', // API host
    i18n: {...},                        // object with translation strings, see code
    units: 'metric',                    // or 'imperial'; temperature scale
    temperatureDigits: 0,               // how many decimal digits in temperature
    maxAgeSeconds: 24*60*60,            // 24h; how long the weather data is considered worth showing
}));

Keywords

openweathermap

FAQs

Package last updated on 03 Dec 2014

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