# Leaflet.GridLayer.FadeOut

A plugin for [LeafletJS](http://www.leafletjs.com) to fade out grid layers when removed.

Fading out base gridlayers makes switching baselayers much smoother to the naked eye. See the [demo](http://ivansanchez.gitlab.io/Leaflet.GridLayer.FadeOut/demo.html)!

Tested with Leaflet 1.0.0-rc3. Do not expect this to work in Leaflet 0.7.x.

### API

This Leaflet plugin is completely transparent, and adds no extra methods or options.

To use it, simply make sure that you have some gridlayers / tilelayers that are removed from the map. This can be done by using a layers control with several base layers.

### Installation through `npm`

```
npm install leaflet.gridlayer.fadeout
```

### Usage through unpkg

```
<script src='https://unpkg.com/leaflet.gridlayer.fadeout@0.1.0/Leaflet.GridLayer.FadeOut.js'></script>
```

### Legalese


"THE BEER-WARE LICENSE":
<ivan@sanchezortega.es> wrote this file. As long as you retain this notice you
can do whatever you want with this stuff. If we meet some day, and you think
this stuff is worth it, you can buy me a beer in return.


