mkdocs-table-reader-plugin


Namemkdocs-table-reader-plugin JSON
Version 3.0.0 PyPI version JSON
download
home_pagehttps://github.com/timvink/mkdocs-table-reader-plugin
SummaryMkDocs plugin to directly insert tables from files into markdown.
upload_time2024-08-15 12:17:48
maintainerNone
docs_urlNone
authorTim Vink
requires_python>=3.8
licenseMIT
keywords mkdocs plugin
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            [![Actions Status](https://github.com/timvink/mkdocs-table-reader-plugin/workflows/pytest/badge.svg)](https://github.com/timvink/mkdocs-table-reader-plugin/actions)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/mkdocs-table-reader-plugin)
![PyPI](https://img.shields.io/pypi/v/mkdocs-table-reader-plugin)
![PyPI - Downloads](https://img.shields.io/pypi/dm/mkdocs-table-reader-plugin)
[![codecov](https://codecov.io/gh/timvink/mkdocs-table-reader-plugin/branch/master/graph/badge.svg)](https://codecov.io/gh/timvink/mkdocs-table-reader-plugin)
![GitHub contributors](https://img.shields.io/github/contributors/timvink/mkdocs-table-reader-plugin)
![PyPI - License](https://img.shields.io/pypi/l/mkdocs-table-reader-plugin)

# mkdocs-table-reader-plugin

[MkDocs](https://www.mkdocs.org/) plugin that enables a markdown tag like `{{ read_csv('table.csv') }}` to directly insert various table formats into a page. 

> For a workflow with other plugins see the blogpost [building reproducible reports with MkDocs](https://timvink.nl/reproducible-reports-with-mkdocs/)

## Installation

Install the plugin using `pip`:

```bash
pip install mkdocs-table-reader-plugin
```

Next, add the following lines to your `mkdocs.yml`:

```yml
plugins:
  - search
  - table-reader
```

> If you have no `plugins` entry in your config file yet, you'll likely also want to add the `search` plugin. MkDocs enables it by default if there is no `plugins` entry set.

## Usage

In your markdown files you can now use:

```html
{{ read_csv('path_to_table.csv') }}
```

Where the path is relative to the location of your project's `mkdocs.yml` file, _or_ your project's `docs/` directory, _or_ the location of your markdown source file (all 3 possible locations will be searched, in that order).

- There are [readers](https://timvink.github.io/mkdocs-table-reader-plugin/readers/) for `.csv`, `.fwf`, `.json`, `.xls`, `.xlsx`, `.yaml`, `.feather` and `.tsv` files. There is also the `read_raw()` reader that will allow you to insert tables (or other content) already in markdown format.
- `table-reader` is compatible with [`mkdocs-macros-plugin`](https://mkdocs-macros-plugin.readthedocs.io/en/latest/), which means you can [dynamically insert tables using jinja2 syntax](https://timvink.github.io/mkdocs-table-reader-plugin/howto/use_jinja2/).

## Documentation and how-to guides

See [timvink.github.io/mkdocs-table-reader-plugin/](https://timvink.github.io/mkdocs-table-reader-plugin/)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/timvink/mkdocs-table-reader-plugin",
    "name": "mkdocs-table-reader-plugin",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "mkdocs plugin",
    "author": "Tim Vink",
    "author_email": "vinktim@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/29/22/0a3d74d24a40fe848f1ef72e80a688738c558a82ce7e00eebbeb970736d1/mkdocs_table_reader_plugin-3.0.0.tar.gz",
    "platform": null,
    "description": "[![Actions Status](https://github.com/timvink/mkdocs-table-reader-plugin/workflows/pytest/badge.svg)](https://github.com/timvink/mkdocs-table-reader-plugin/actions)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/mkdocs-table-reader-plugin)\n![PyPI](https://img.shields.io/pypi/v/mkdocs-table-reader-plugin)\n![PyPI - Downloads](https://img.shields.io/pypi/dm/mkdocs-table-reader-plugin)\n[![codecov](https://codecov.io/gh/timvink/mkdocs-table-reader-plugin/branch/master/graph/badge.svg)](https://codecov.io/gh/timvink/mkdocs-table-reader-plugin)\n![GitHub contributors](https://img.shields.io/github/contributors/timvink/mkdocs-table-reader-plugin)\n![PyPI - License](https://img.shields.io/pypi/l/mkdocs-table-reader-plugin)\n\n# mkdocs-table-reader-plugin\n\n[MkDocs](https://www.mkdocs.org/) plugin that enables a markdown tag like `{{ read_csv('table.csv') }}` to directly insert various table formats into a page. \n\n> For a workflow with other plugins see the blogpost [building reproducible reports with MkDocs](https://timvink.nl/reproducible-reports-with-mkdocs/)\n\n## Installation\n\nInstall the plugin using `pip`:\n\n```bash\npip install mkdocs-table-reader-plugin\n```\n\nNext, add the following lines to your `mkdocs.yml`:\n\n```yml\nplugins:\n  - search\n  - table-reader\n```\n\n> If you have no `plugins` entry in your config file yet, you'll likely also want to add the `search` plugin. MkDocs enables it by default if there is no `plugins` entry set.\n\n## Usage\n\nIn your markdown files you can now use:\n\n```html\n{{ read_csv('path_to_table.csv') }}\n```\n\nWhere the path is relative to the location of your project's `mkdocs.yml` file, _or_ your project's `docs/` directory, _or_ the location of your markdown source file (all 3 possible locations will be searched, in that order).\n\n- There are [readers](https://timvink.github.io/mkdocs-table-reader-plugin/readers/) for `.csv`, `.fwf`, `.json`, `.xls`, `.xlsx`, `.yaml`, `.feather` and `.tsv` files. There is also the `read_raw()` reader that will allow you to insert tables (or other content) already in markdown format.\n- `table-reader` is compatible with [`mkdocs-macros-plugin`](https://mkdocs-macros-plugin.readthedocs.io/en/latest/), which means you can [dynamically insert tables using jinja2 syntax](https://timvink.github.io/mkdocs-table-reader-plugin/howto/use_jinja2/).\n\n## Documentation and how-to guides\n\nSee [timvink.github.io/mkdocs-table-reader-plugin/](https://timvink.github.io/mkdocs-table-reader-plugin/)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "MkDocs plugin to directly insert tables from files into markdown.",
    "version": "3.0.0",
    "project_urls": {
        "Homepage": "https://github.com/timvink/mkdocs-table-reader-plugin"
    },
    "split_keywords": [
        "mkdocs",
        "plugin"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f242b373f2c1972492760f1458832eb3a7f000fcb8f3fe78f67856f9ead1abfc",
                "md5": "f76cdd5cf681fb3ff32ce9523d3b7ba1",
                "sha256": "c1eb87c42fd739857210464c5df44895a12aa8be5631cd928291e800bfe984cf"
            },
            "downloads": -1,
            "filename": "mkdocs_table_reader_plugin-3.0.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "f76cdd5cf681fb3ff32ce9523d3b7ba1",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 10061,
            "upload_time": "2024-08-15T12:17:47",
            "upload_time_iso_8601": "2024-08-15T12:17:47.068402Z",
            "url": "https://files.pythonhosted.org/packages/f2/42/b373f2c1972492760f1458832eb3a7f000fcb8f3fe78f67856f9ead1abfc/mkdocs_table_reader_plugin-3.0.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "29220a3d74d24a40fe848f1ef72e80a688738c558a82ce7e00eebbeb970736d1",
                "md5": "0b672964fdedef4768c518091427dcaf",
                "sha256": "7f4ba36329cc9b34aa48bea914f5bf474f27063a553c5d45a9920a166ce622cb"
            },
            "downloads": -1,
            "filename": "mkdocs_table_reader_plugin-3.0.0.tar.gz",
            "has_sig": false,
            "md5_digest": "0b672964fdedef4768c518091427dcaf",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 11959,
            "upload_time": "2024-08-15T12:17:48",
            "upload_time_iso_8601": "2024-08-15T12:17:48.263005Z",
            "url": "https://files.pythonhosted.org/packages/29/22/0a3d74d24a40fe848f1ef72e80a688738c558a82ce7e00eebbeb970736d1/mkdocs_table_reader_plugin-3.0.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-08-15 12:17:48",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "timvink",
    "github_project": "mkdocs-table-reader-plugin",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "mkdocs-table-reader-plugin"
}
        
Elapsed time: 0.28115s