Skip to main content

fasthtml-lucide

License Release Python versions PyPI version FastHTML Lucide uv Pytest Ruff

Lucide SVG icons for FastHTML. Icons are bundled in the Python package: no Node.js, JavaScript, CDN or static-file setup is needed in your application.

uv add fasthtml-lucide
from fasthtml.common import Button
from fasthtml_lucide import Icon

Button(Icon("sun", cls="size-5 text-yellow-500"), "Light mode")

Icon(name, *, cls="", size=24) accepts kebab-case Lucide names and returns an inline SVG. Colors inherit through currentColor. Original SVG classes are kept. Invalid or unknown names raise ValueError. The generated IconName type lists every bundled icon, so type checkers can flag misspelled names and editors can suggest valid ones. You can also import IconName to annotate your own variables and parameters.

Icons are decorative (aria-hidden="true"). Give icon-only buttons an accessible label on the button itself.

The library is automatically updated to the latest stable lucide-static release on npm, with checks running daily. The PyPI version matches the npm version; Python-only fixes may add a .postN suffix.

Development

Build

Requires Python 3.11+, uv and Node.js/npm when building from Git:

uv build

The build hook downloads the matching lucide-static release and bundles its SVGs and license in both the wheel and sdist. Building from the sdist does not require Node.js/npm.

To run the tests against the built package:

uv venv
uv pip install --group test dist/*.whl
uv run --no-project python -m pytest tests
uv run --no-project python scripts/check_dist.py

Automated releases

The Release workflow checks npm daily and can also be run manually. It updates the package version, builds and tests the release, creates a Git tag and publishes to PyPI using Trusted Publishing.

Manual releases

For a Python-only fix, increment the post-release version (for example, 1.61.0 → 1.61.0.post1 → 1.61.0.post2):

uv version --bump post --frozen --no-sync

Commit your fix and pyproject.toml, push to the default branch, then select Actions → Release → Run workflow on GitHub. The workflow creates the tag and publishes to PyPI. The Lucide version stays the same unless a newer npm release is available.

License

The Python wrapper is MIT licensed. Bundled Lucide icons retain the upstream ISC license and the MIT notices for icons derived from Feather, included in fasthtml_lucide/LUCIDE-LICENSE.

Metadata

Release files for fasthtml-lucide 1.61.0

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

Source distribution (sdist)

Source distribution for fasthtml-lucide 1.61.0
File Size Uploaded Provenance
fasthtml_lucide-1.61.0.tar.gz 169.6 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for fasthtml-lucide 1.61.0
File Interpreter ABI Platform
fasthtml_lucide-1.61.0-py3-none-any.whl Python 3 none any Details

Total release size: 1.2 MB

Release files / fasthtml_lucide-1.61.0.tar.gz

Download URL fasthtml_lucide-1.61.0.tar.gz
Size 169.6 kB
Tags Source
SHA-256 checksum
How to use checksums
2e51166190ff167ed3d0393536548ad6d68b96341c63ea98fbffc35782464298
BLAKE2b-256 checksum
How to use checksums
6e783690db2eda1245ef22d410fc815c8e2746513d996e4c835b76e0b49b7b94
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.5 {"installer":{"name":"uv","version":"0.13.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / fasthtml_lucide-1.61.0-py3-none-any.whl

Download URL fasthtml_lucide-1.61.0-py3-none-any.whl
Size 1.0 MB
Tags Python 3
SHA-256 checksum
How to use checksums
629733715fdc3af52cb495a6d2ef2980edb7b14e43995ef368c4d038371ab511
BLAKE2b-256 checksum
How to use checksums
6d0d7300f37a9bb7dad34fe3d3e5de527e18c736b85161dcd8f4a8dfd4a4e5a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via uv/0.13.5 {"installer":{"name":"uv","version":"0.13.5","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for fasthtml-lucide 1.61.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.61.0 This release

2 release files No provenance

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