starMERGE
A comprehensive Python port of tailwind-merge - intelligently merge Tailwind CSS classes without style conflicts.
Description
starmerge is a utility function to efficiently merge Tailwind CSS classes in Python without style conflicts. This is a complete port of the popular JavaScript library tailwind-merge.
from starmerge import merge
merge("px-2 py-1 bg-red hover:bg-dark-red", "p-3 bg-[#B91C1C]")
# → 'hover:bg-dark-red p-3 bg-[#B91C1C]'
Installation
pip install starmerge
Features
- ✅ Full class merging functionality with conflict resolution
- ✅ Support for Tailwind v4.x syntax
- ✅ Handles arbitrary values, modifiers, and variants
- ✅ Comprehensive test coverage matching the original library
- ✅ Production-ready and battle-tested
Requirements
- Python 3.11+
- Works with Tailwind CSS v4.x
Contributing
Contributions are welcome! Feel free to open issues for bugs or unexpected behavior, or submit pull requests with improvements.
Credits
This is a port of tailwind-merge by Dany Castillo. All credit for the original implementation goes to the original authors.
License
Licensed under the MIT License. This is a port of tailwind-merge which is also licensed under the MIT License.
Disclaimer
This is an independent port and is not officially affiliated with or endorsed by the original tailwind-merge project or Tailwind CSS.
Metadata
Release files for starmerge 0.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| starmerge-0.2.1.tar.gz | 59.8 kB | With provenance | Details for starmerge-0.2.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| starmerge-0.2.1-py3-none-any.whl | Python 3 | none | any | Details for starmerge-0.2.1-py3-none-any.whl |
Total release size: 81.9 kB
Release files / starmerge-0.2.1.tar.gz
| Download URL | starmerge-0.2.1.tar.gz |
|---|---|
| Size | 59.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9d3682de1cef09f5535009180648cdf1e0c6c6f64f4ed69cf908d3f6f1cc8bbb
|
|
BLAKE2b-256 checksum How to use checksums |
f855b4f987b4e7890a3cdefcb1a22a35c53a6653d11024bed7ac3ca1921a8826
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 1, 2026.
Transparency logRelease files / starmerge-0.2.1-py3-none-any.whl
| Download URL | starmerge-0.2.1-py3-none-any.whl |
|---|---|
| Size | 22.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e6318357a70fb698888cec34039c34006d48be2f738f339d797529146c6b89f1
|
|
BLAKE2b-256 checksum How to use checksums |
e4d0b72f72e81f2c4447631e420fca16acfe3dd9f3edc0a545adb1a9b8db0114
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 1, 2026.
Transparency logSecurity for starmerge 0.2.1
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.
Full provenance
Both files in this release have been uploaded with provenance metadata.
Attestation for starmerge-0.2.1.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Mar 1, 2026.
Transparency logA 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.