Embed the data source specifications in your JINJA templates directly, and enjoy the dynamic data contexts.
Project description
eds4jinja2
An easy way to reports generation with Jinja2 templates.
With Embedded Datasource Specifications inside Jinja2 templates, you can fetch the data you need on the spot.
Specify the data sources in your JINJA templates directly.
{% set content, error = from_file(path).fetch_tree() %} \n
content: {{ content }}\n
error: {{ error }}\n
{% set content, error =
from_endpoint(endpoint).with_query(query_string).fetch_tabular() %}
content: {{ content }} \n
error: {{ error }} \n
Installation
pip install eds4jinja2
Usage
Contributing
You are more than welcome to help expand and mature this project. We adhere to Apache code of conduct, please follow it in all your interactions on the project.
When contributing to this repository, please first discuss the change you wish to make via issue, email, or any other method with the maintainers of this repository before making a change.
Licence
This project is licensed under GNU GPLv3 licence. Powered by Meaningfy.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for eds4jinja2-0.1.30-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 485fa8b3459710c69db0ce44a48a680e76f8a6151b94c328312b639295ffcaf7 |
|
MD5 | 2afb9dd7f65c431a603220b456bbd102 |
|
BLAKE2b-256 | c5e52e2176fab8050f8e84dcfe7bdb262c4136cb38e908e063f73b788a7fc6de |