![Create React App Officially Deprecated Amid React 19 Compatibility Issues](https://cdn.sanity.io/images/cgdhsj6q/production/04fa08cf844d798abc0e1a6391c129363cc7e2ab-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
.. image:: https://badge.fury.io/py/templated-docs.svg :target: https://pypi.python.org/pypi/templateddocs
.. image:: https://img.shields.io/travis/kiawin/templated-docs.svg :target: https://travis-ci.org/kiawin/templated-docs
.. image:: https://readthedocs.org/projects/templated-docs/badge/?version=latest :target: https://templated-docs.readthedocs.io/en/latest/?badge=latest :alt: Documentation Status
.. image:: https://requires.io/github/kiawin/templated-docs/requirements.svg?branch=master :target: https://requires.io/github/kiawin/templated-docs/requirements?branch=master :alt: Dependencies
Generate templated documents within Django in any format supported by LibreOffice: texts, spreadsheets, presentations etc.
Create a sample.odt
document (make sure it's in OpenDocument format) and
put it in your Django templates folder. It should look something like this:
.. image:: https://github.com/kiawin/templated-docs/raw/master/docs/document-template.png
Then write a view to generate documents from this template:
.. code-block:: python
from templated_docs import fill_template
from templated_docs.http import FileResponse
def get_document(request):
"""
A view to get a document filled with context variables.
"""
context = {'user': request.user} # Just an example
filename = fill_template('sample.odt', context, output_format='pdf')
visible_filename = 'greeting.pdf'
return FileResponse(filename, visible_filename)
Navigate to the url your view is connected to, and you'll see a rendered and converted document:
.. image:: https://github.com/kiawin/templated-docs/raw/master/docs/generated-document.png
For more examples, see the examples/
subfolder in the repository. More detailed documentation is available on https://templated-docs.readthedocs.io.
Templated-docs was written by Alex Morozov
_.
As the repository is left idle for 2 years, Sian Lerk Lau
_ has forked and resume the task of updating the module.
This package was created with Cookiecutter_ and the audreyr/cookiecutter-pypackage
_ project template.
.. _Cookiecutter: https://github.com/audreyr/cookiecutter
.. _audreyr/cookiecutter-pypackage
: https://github.com/audreyr/cookiecutter-pypackage
.. _pylokit: https://github.com/xrmx/pylokit
.. _Alex Morozov
: http://morozov.ca
.. _Sian Lerk Lau
: https://github.com/kiawin
FAQs
Generate PDF, MS Word and Excel documents from templates in Django.
We found that jpt-templated-docs demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.