diff --git a/.npmignore b/.npmignore index 3ed09ab..de4110c 100644 --- a/.npmignore +++ b/.npmignore @@ -1 +1,3 @@ -assets/ \ No newline at end of file +assets/ +_config.yml +.npmignore diff --git a/README.md b/README.md index 6e2bc96..1ba7cfd 100644 --- a/README.md +++ b/README.md @@ -53,6 +53,36 @@ Has only been tested with Leaflet ^1.7.1 ``` +### Installing the sub-plugin + +#### Local copy + +1. Download the [`leaflet.layergroup.conditional.js`](https://solfisk.github.io/Leaflet.LayerGroup.Conditional/leaflet.layergroup.conditional.js) file from the latest release. +2. Place the file alongside your page. +3. Add the `script` tag to your page after Leaflet script. + +#### CDN + +You can alternatively use the free [unpkg](https://unpkg.com) CDN service: + +```html + + +``` + +#### npm + +1. Add this package to your project: + + ```bash + npm install leaflet-layergroup-conditional --save + ``` + +2. Add `script` tag to your page after Leaflet script: + ```html + + + ``` ## API Reference @@ -83,4 +113,4 @@ Methods are the same as those of [LayerGroup](http://leafletjs.com/reference.htm ## License -GPL. +[GNU GPLv3](https://www.gnu.org/licenses/gpl-3.0-standalone.html) or later diff --git a/package.json b/package.json index e5765e9..aa05188 100644 --- a/package.json +++ b/package.json @@ -4,10 +4,11 @@ "description": "An extension af Leaflet.LayerGroup with conditional layers.", "keywords": ["leaflet", "layergroup", "conditional"], "repository": "github:Solfisk/Leaflet.LayerGroup.Conditional", + "homepage": "https://solfisk.github.io/Leaflet.LayerGroup.Conditional", "main": "Leaflet.LayerGroup.Conditional.js", "author": "Jørgen Elgaard Larsen ", "license": "GPL-3.0-or-later", "peerDependencies": { "leaflet": "^1.0.0" } - } \ No newline at end of file +}