datasette-leaflet-geojson


Namedatasette-leaflet-geojson JSON
Version 0.8.2 PyPI version JSON
download
home_pagehttps://github.com/simonw/datasette-leaflet-geojson
SummaryA Datasette plugin that renders GeoJSON columns using Leaflet
upload_time2024-04-25 05:05:34
maintainerNone
docs_urlNone
authorSimon Willison
requires_pythonNone
licenseApache License, Version 2.0
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # datasette-leaflet-geojson

[![PyPI](https://img.shields.io/pypi/v/datasette-leaflet-geojson.svg)](https://pypi.org/project/datasette-leaflet-geojson/)
[![Changelog](https://img.shields.io/github/v/release/simonw/datasette-leaflet-geojson?include_prereleases&label=changelog)](https://github.com/simonw/datasette-leaflet-geojson/releases)
[![Tests](https://github.com/simonw/datasette-leaflet-geojson/workflows/Test/badge.svg)](https://github.com/simonw/datasette-leaflet-geojson/actions?query=workflow%3ATest)
[![License](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](https://github.com/simonw/datasette-leaflet-geojson/blob/main/LICENSE)

Datasette plugin that replaces any GeoJSON column values with a Leaflet map

## Installation

Install this plugin in the same environment as Datasette.

    $ datasette install datasette-leaflet-geojson

## Usage

Any columns containing valid GeoJSON strings will have their contents replaced with a Leaflet map when they are displayed in the Datasette interface.

## Demo

You can try this plugin out at https://calands.datasettes.com/calands/superunits_with_maps

![datasette-leaflet-geojson in action](https://raw.github.com/simonw/datasette-leaflet-geojson/main/datasette-leaflet-geojson.png)

## Configuration

By default this plugin displays maps for the first ten rows, and shows a "Click to load map" prompt for rows past the first ten.

You can change this limit using the `default_maps_to_load` plugin configuration setting. Add this to your `metadata.json`:

```json
{
    "plugins": {
        "datasette-leaflet-geojson": {
            "default_maps_to_load": 20
        }
    }
}
```
Then run Datasette with `datasette mydb.db -m metadata.json`.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/simonw/datasette-leaflet-geojson",
    "name": "datasette-leaflet-geojson",
    "maintainer": null,
    "docs_url": null,
    "requires_python": null,
    "maintainer_email": null,
    "keywords": null,
    "author": "Simon Willison",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/0f/80/914c65057714798c97bdcdaaa480dcdcb94c246358d00cd185e9e9c91fa1/datasette_leaflet_geojson-0.8.2.tar.gz",
    "platform": null,
    "description": "# datasette-leaflet-geojson\n\n[![PyPI](https://img.shields.io/pypi/v/datasette-leaflet-geojson.svg)](https://pypi.org/project/datasette-leaflet-geojson/)\n[![Changelog](https://img.shields.io/github/v/release/simonw/datasette-leaflet-geojson?include_prereleases&label=changelog)](https://github.com/simonw/datasette-leaflet-geojson/releases)\n[![Tests](https://github.com/simonw/datasette-leaflet-geojson/workflows/Test/badge.svg)](https://github.com/simonw/datasette-leaflet-geojson/actions?query=workflow%3ATest)\n[![License](https://img.shields.io/badge/license-Apache%202.0-blue.svg)](https://github.com/simonw/datasette-leaflet-geojson/blob/main/LICENSE)\n\nDatasette plugin that replaces any GeoJSON column values with a Leaflet map\n\n## Installation\n\nInstall this plugin in the same environment as Datasette.\n\n    $ datasette install datasette-leaflet-geojson\n\n## Usage\n\nAny columns containing valid GeoJSON strings will have their contents replaced with a Leaflet map when they are displayed in the Datasette interface.\n\n## Demo\n\nYou can try this plugin out at https://calands.datasettes.com/calands/superunits_with_maps\n\n![datasette-leaflet-geojson in action](https://raw.github.com/simonw/datasette-leaflet-geojson/main/datasette-leaflet-geojson.png)\n\n## Configuration\n\nBy default this plugin displays maps for the first ten rows, and shows a \"Click to load map\" prompt for rows past the first ten.\n\nYou can change this limit using the `default_maps_to_load` plugin configuration setting. Add this to your `metadata.json`:\n\n```json\n{\n    \"plugins\": {\n        \"datasette-leaflet-geojson\": {\n            \"default_maps_to_load\": 20\n        }\n    }\n}\n```\nThen run Datasette with `datasette mydb.db -m metadata.json`.\n",
    "bugtrack_url": null,
    "license": "Apache License, Version 2.0",
    "summary": "A Datasette plugin that renders GeoJSON columns using Leaflet",
    "version": "0.8.2",
    "project_urls": {
        "Homepage": "https://github.com/simonw/datasette-leaflet-geojson"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a342f119c40f5e436300a3ae8bc9e23e6667c6964da5974238bf05298b2f0a59",
                "md5": "8481a71a27f211e996cfd9f33d40dfda",
                "sha256": "cbc64db5c6ec8d75de2c3390e6ce0cc680ab71105434692aad5e7400393a8a24"
            },
            "downloads": -1,
            "filename": "datasette_leaflet_geojson-0.8.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "8481a71a27f211e996cfd9f33d40dfda",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": null,
            "size": 5056,
            "upload_time": "2024-04-25T05:05:32",
            "upload_time_iso_8601": "2024-04-25T05:05:32.926957Z",
            "url": "https://files.pythonhosted.org/packages/a3/42/f119c40f5e436300a3ae8bc9e23e6667c6964da5974238bf05298b2f0a59/datasette_leaflet_geojson-0.8.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0f80914c65057714798c97bdcdaaa480dcdcb94c246358d00cd185e9e9c91fa1",
                "md5": "8fbfe06ce86e2714284f44626612d9ce",
                "sha256": "d72e5390b7cb3bafcc8792d1353e053165920876d56ee6185c7b4480bbec6d06"
            },
            "downloads": -1,
            "filename": "datasette_leaflet_geojson-0.8.2.tar.gz",
            "has_sig": false,
            "md5_digest": "8fbfe06ce86e2714284f44626612d9ce",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 4998,
            "upload_time": "2024-04-25T05:05:34",
            "upload_time_iso_8601": "2024-04-25T05:05:34.401026Z",
            "url": "https://files.pythonhosted.org/packages/0f/80/914c65057714798c97bdcdaaa480dcdcb94c246358d00cd185e9e9c91fa1/datasette_leaflet_geojson-0.8.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-04-25 05:05:34",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "simonw",
    "github_project": "datasette-leaflet-geojson",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "datasette-leaflet-geojson"
}
        
Elapsed time: 0.24115s