Skip to main content

To create the content for the README.md file of your Python package, you can include the following information:

PDF Generator

A Python package for converting JSON data to HTML and generating PDFs.

Description

This package provides functionality to convert JSON data to HTML using a customizable template and then generate PDF files from the HTML content. It allows users to provide their own JSON data and template file to customize the output.

Features

  • Convert JSON data to HTML - anyName.json
  • Support for custom HTML templates - template.html
  • Generate PDF files from HTML - output.html
  • Merge multiple PDF files into a single PDF - merged_output.pdf

Installation

You can install the package using pip:

pip install oneoneoneexample==0.6

Note: Replace "version-number" with the recent version number of the package, ex: 0.6 -> latest.

Usage

from pdf_generator.convert import generate

# Specify the paths and file names for JSON data, template, output HTML, and new PDF file
json_file = 'path/to/json/data.json' (complete path of json file)
template_directory = 'path/to/template/directory' (only template directory)
output_html_path = 'path/to/save/output/html' (only output html directory)
new_pdf_path = 'path/to/save/new/pdf' (only pdf saving directory)

# Generate HTML and PDF files
generate(json_file, template_directory, output_html_path, new_pdf_path)

Make sure to replace the placeholders with the actual paths and file names.

Dependencies

This package relies on the following dependencies:

  • pandas
  • jinja2
  • pdfkit
  • PyPDF2

Please make sure to install these dependencies before using the package. You can install them using the following command:

pip install pandas jinja2 pdfkit PyPDF2

Note: The pdfkit library requires an external tool called Wkhtmltopdf. This package will automatically add the path for Wkhtmltopdf still error of Wkhtmltopdf installation, add path to your system's PATH before using this package.

License

This package is licensed under the MIT License.

Release files for oneoneoneexample 0.8

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for oneoneoneexample 0.8
File Size Uploaded
oneoneoneexample-0.8.tar.gz 4.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for oneoneoneexample 0.8
File Interpreter ABI Platform
oneoneoneexample-0.8-py3-none-any.whl Python 3 none any Details

Total release size: 9.8 kB

Release files / oneoneoneexample-0.8.tar.gz

Download URL oneoneoneexample-0.8.tar.gz
Size 4.0 kB
Tags Source
SHA-256 checksum
How to use checksums
07b4ed9684abd1c6a1c694bf44a84027a04a4e488d420381302b9e3f16350048
BLAKE2b-256 checksum
How to use checksums
f05ee8851250d3dc8626770ab4f06a75561523b9d4073f374af55276116ca171
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.2

Release files / oneoneoneexample-0.8-py3-none-any.whl

Download URL oneoneoneexample-0.8-py3-none-any.whl
Size 5.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
f68411b21c70347974ad466e95c1f4c8e118b2e67222bb757e10dae1b2a32c6c
BLAKE2b-256 checksum
How to use checksums
b2e35641d932d978b4f44ef544e8dbfbbd6fa547585422c097f46fd4dfba9b22
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.2

Release history Release notifications | RSS feed

This release

0.8 This release

2 release files

0.7

2 release files

0.6

2 release files

0.5

2 release files

0.4

2 release files

0.3

2 release files

0.2

2 release files

0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page