Amantadine is a framework for rendering HTML on the server
Project description
Amantadine
Amantadine is a framework for rendering HTML on the server
It is not ready for production.
Introduce
The heavy HTML, CSS and JS files are rendered into independent HTML files, and asynchronous data collection through network requests is supported, and functions are defined as parameters. Only render CSS tags used in HTML to reduce volume
Install
pip install -U amantadine
Usage
import amantadine
pages = amantadine.Pages(
body=[amantadine.Record("h1", [amantadine.OnlyText("Amantadine")])],
head=[
amantadine.Record("meta", attrs={"charset": "UTF-8"}),
amantadine.Record("title", [amantadine.OnlyText("Amantadine")]),
],
)
print(amantadine.renderDoc(pages))
After rendering:
<!DOCTYPE html>
<html lang="en">
<head>
<meta class='' charset=UTF-8></meta>
<title class=''>Amantadine</title>
</head>
<body>
<h1 class=''>Amantadine</h1>
</body>
</html>
License
MIT LICENSE
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
amantadine-0.0.3.tar.gz
(3.6 kB
view details)
Built Distribution
amantadine-0.0.3-py3.8.egg
(11.3 kB
view details)
File details
Details for the file amantadine-0.0.3.tar.gz
.
File metadata
- Download URL: amantadine-0.0.3.tar.gz
- Upload date:
- Size: 3.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | de019e1e40079f91dcedb60411e4347a82650a8eecb8ae9921cf3c794bcb4258 |
|
MD5 | 4610927dd5b97358f7a96399e7780320 |
|
BLAKE2b-256 | 4623a2e7b54c9836865ae43b082a4b0c9bb16954cbaad730642007a6b6e1e1f2 |
File details
Details for the file amantadine-0.0.3-py3.8.egg
.
File metadata
- Download URL: amantadine-0.0.3-py3.8.egg
- Upload date:
- Size: 11.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.24.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6d1ecffdd7aa1ee8c39bb317e53d6237e67c26a35a6253992264c6c03a2030ff |
|
MD5 | be27b739da9f1734bb733f147577ab5c |
|
BLAKE2b-256 | 58bc7e1621cb4a53ea1021de133d593e42d05347c57d73f9c7e2ce287261e56e |