# leaflet-smooth-heatmap

> Serverless smooth and unbroken heatmap tile layer

Latest version **1.0.0** (published 2018-01-10) · ISC license · 0 weekly downloads

## Install

```sh
npm install leaflet-smooth-heatmap
pnpm add leaflet-smooth-heatmap
yarn add leaflet-smooth-heatmap
bun add leaflet-smooth-heatmap
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2018-01-10 |
| First published | 2018-01-10 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Maintainers | z3ut |
| Keywords | leaflet, smooth, heatmap, layer |

## Links

- npm: https://www.npmjs.com/package/leaflet-smooth-heatmap
- Repository: https://github.com/z3ut/leaflet-smooth-heatmap
- Homepage: https://github.com/z3ut/leaflet-smooth-heatmap#readme
- Issues: https://github.com/z3ut/leaflet-smooth-heatmap/issues
- npm.io page: https://npm.io/package/leaflet-smooth-heatmap

## Recent versions

- 1.0.0 (latest) — 2018-01-10

## README

# Leaflet Smooth Heatmap

Serverless smooth and unbroken heatmap tile layer.

[Live Demo](https://z3ut.github.io/leaflet-smooth-heatmap/)

## Description

Canvas tile layer. Each tile filled with grid of rectangles. Rectangle color requested by coordinates of it center.

Not intended for use on low-performance devices.

## Installation

1. Install with [npm](https://www.npmjs.com)

```
npm install leaflet-smooth-heatmap
```

2. Import JS dependencies

```
import { SmoothHeatmapLayer } from 'leaflet-smooth-heatmap';
```

or include src/index.js to your bundle and use plugin through global L variable

## Usage

```
const options = {
  canvasSize: 5,
  getColorForLatLng: (lat, lng) => `rgba(${90 + lat}, ${180 + lng}, 100, .5)`
};
map.addLayer( new SmoothHeatmapLayer(options)) );
```

Example with data point interpolation in ./docs

### Options

Name | Description | Type | Default
--- | --- | --- | ---
canvasSize | Size of rectangles in canvas (low values influence on performance) | Number | 3
getColorForLatLng | Return color for point coordinates. Arguments - lat, lng | Function | function() { return 'rgba(0, 0, 0, 0);' }

---
_Source: https://npm.io/package/leaflet-smooth-heatmap · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
