A simple HTML builder for Python.
Project description
pyhtmlbuilder
Build HTML with Python.
Installation
pip install pyhtmbuilder
Example
from pyhtmbuilder import *
html = Html(
Head(),
Body(
Div(
H1("Hello World"),
P("Built with pyhtmbuilder")
)
)
)
print(html)
Output:
<html>
<head>
</head>
<body>
<div>
<h1>Hello World</h1>
<p>Built with pyhtmbuilder</p>
</div>
</body>
</html>
Features
-
Simple API
-
Pure Python
-
HTML Tree Structure
-
Export to
.htmlfiles
Current Tags
Container Tags
-
Html
-
Head
-
Body
-
Div
Text Tags
-
H1
-
P
Requirements
Python 3.10+
License
MIT License
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
pyhtmbuilder-0.1.0.tar.gz
(1.9 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pyhtmbuilder-0.1.0.tar.gz.
File metadata
- Download URL: pyhtmbuilder-0.1.0.tar.gz
- Upload date:
- Size: 1.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
36282e03e738282ad9a9c2a9097a8bf09cd6cde84e3bd7c4ea774589d017e34b
|
|
| MD5 |
ec33017cb809655ece12e05d37811200
|
|
| BLAKE2b-256 |
a8a01e9ffc69f600c2e49cd27cfe4e4ef7b4923059f79e428fe74a404736b572
|
File details
Details for the file pyhtmbuilder-0.1.0-py3-none-any.whl.
File metadata
- Download URL: pyhtmbuilder-0.1.0-py3-none-any.whl
- Upload date:
- Size: 2.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2a3b9649ba1d557d0e70713cfd4c623c4ff7d49284d27e4357daf8f4998fb2b5
|
|
| MD5 |
750c70809027733a5364cf3d8a5d6dc9
|
|
| BLAKE2b-256 |
478b55e5590600341c03e9f336f3cfbaa31e27580d382af23162595196d9a0f7
|