Skip to main content

Tailwind CSS classes processor

Project description

Tailwind Processor

codecov

This is a Python package that processes Tailwind CSS classes into a single raw CSS string. It's super modular and simple, you can just copy the class directly and use it in your code. Just make sure to install pytailwindcss first.

It uses GO style error handling.

Installation

pip install tailwind-processor

Usage

from tailwind_processor import TailwindProcessor

tp = TailwindProcessor()

result, err = tp.process(["text-red-500", "h-dvh"])
if err:
    # Or do another thing
    raise err

file_content = textwrap.dedent("""
    <div class="text-red-500 h-dvh">
        Hey!
    </div>
""")

result, err = tp.process_file_str(file_content)

if err:
    # Or do another thing
    raise err

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

tailwind_processor-2.0.0.tar.gz (4.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tailwind_processor-2.0.0-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file tailwind_processor-2.0.0.tar.gz.

File metadata

  • Download URL: tailwind_processor-2.0.0.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.9

File hashes

Hashes for tailwind_processor-2.0.0.tar.gz
Algorithm Hash digest
SHA256 7a9326dcb6e2e4096389f7d34f63fcbd86dabcbe5c89a46aff97570f42db9e1f
MD5 3a3c44042b59ba65798cabe698d24c2b
BLAKE2b-256 1591acf85eedce0c87c32ccac58875ae9626eaf289c7a700197b88a52b5cb3da

See more details on using hashes here.

File details

Details for the file tailwind_processor-2.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for tailwind_processor-2.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9d2ac71fd19485dd051ccbcbf71ecda20c3b3bdc764d10d0329657bbf957accf
MD5 c49816a80c241ec3c089afa471153832
BLAKE2b-256 5e7609fc8dc3aab62bd178b7b352fce0225185ee34101e32a17612d134f6c6a5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page