Skip to main content

Pelican plugin to add TailwindCSS to your website.

Project description

TailwindCSS Plugin for Pelican 🌬

Build Status PyPI Version License

This plugin helps you use TailwindCSS in your Pelican website.

Author GitHub Twitter
Luca Fedrizzi https://github.com/lcfd https://twitter.com/lc_fd

Why Use This Plugin?

Because you want use TailwindCSS in seconds. Not hours.

Installation

This plugin can be installed via:

python -m pip install pelican-tailwindcss

or

poetry add pelican-tailwindcss

Basic Usage

  1. Create a tailwind.config.js file in your Pelican project root folder containing:

    /** @type {import('tailwindcss').Config} */
    module.exports = {
    content: ["./themes/**/*.html", "./themes/**/*.js"],
    theme: {
        extend: {},
    },
    plugins: [],
    };
    

    The content property values are just suggestions. Feel free to modify them according to your needs.

  2. Create a input.css file in your Pelican project root folder containing:

    @tailwind base;
    @tailwind components;
    @tailwind utilities;
    
  3. Add the build file (output.css) in your base.html.

    <link rel="stylesheet" href="/output.css" />
    
  4. Done! You should be ready to use TailwindCSS in your website template.

Advanced Usage

In your settings you can configure the plugin's behavior using the TAILWIND setting.

An example of a complete TAILWIND setting:

TAILWIND = {
    "version": "3.0.0"
}

Contributing

Contributions are welcome and much appreciated. Every little bit helps. You can contribute by improving the documentation, adding missing features, and fixing bugs. You can also help out by reviewing and commenting on existing issues.

To start contributing to this plugin, review the Contributing to Pelican documentation, beginning with the Contributing Code section.

License

This project is licensed under the AGPL-3.0 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

pelican-tailwindcss-0.1.0.tar.gz (4.6 kB view hashes)

Uploaded Source

Built Distribution

pelican_tailwindcss-0.1.0-py3-none-any.whl (5.0 kB view hashes)

Uploaded Python 3

Supported by

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