air-convert
Utility for converting HTML to Air Tags
- PyPI package: https://pypi.org/project/air-convert/
- Free software: MIT License
- Documentation: https://github.com/feldroy/air_convert
Installation
Pip:
pip install air-covert
UV:
uv add air-covert
Usage from the command line
air-convert local/path/to/my/page.html
When combined with curl or wget:
curl -o page.html https://example.com && air-convert page.html
wget -O page.html https://example.com && air-convert page.html
Programmatic usage
from air_convert import html_to_airtags
html_to_airtags("""
<main>
<article class="prose">
<h1>Hello, world</h1>
<p>Let's soar into the air!</p>
</article>
</main>
""")
Generates:
air.Main(
air.Article(
air.H1("Hello, world"),
air.P("Let\'s soar into the air!"),
class_="prose"
)
)
Credits
- This package was created with the awesome Cookiecutter and the audreyfeldroy/cookiecutter-pypackage project template.
- Uses the elegant Typer framework to provide a CLI interface
- Relies on BeautifulSoup4 for parsing of HTML
- Formatting of generated code provided by Ruff
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
air_convert-0.3.0.tar.gz
(12.2 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 air_convert-0.3.0.tar.gz.
File metadata
- Download URL: air_convert-0.3.0.tar.gz
- Upload date:
- Size: 12.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ca278f3cdb140009e1ec657ca349d8f6c63097c1a9af75f5f8aabc9f7bb5a835
|
|
| MD5 |
e1110df843f5ce093655025beb5b5616
|
|
| BLAKE2b-256 |
8bf241180baabb64ccc5f19fc9956e6f6088819c9d0b2e243a38a16049bff9a9
|
File details
Details for the file air_convert-0.3.0-py3-none-any.whl.
File metadata
- Download URL: air_convert-0.3.0-py3-none-any.whl
- Upload date:
- Size: 6.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.8.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
986869fac6a303b25ab3dead5153fe554ac51ea9b55cf14f9c5e249696f399d2
|
|
| MD5 |
8c0232e90a6d8dd6996d91fd27040a59
|
|
| BLAKE2b-256 |
97c9838ab957393be304de348bd93004a86282ac69b6fdf67a07218a5989ceec
|