JSPM

tailwind-shades-for-custom-colors

1.0.2
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1
  • Score
    100M100P100Q45926F
  • License MIT

Autogenerate up to 10 shades for your custom colors defined in tailwind.config.js

Package Exports

  • tailwind-shades-for-custom-colors
  • tailwind-shades-for-custom-colors/dist/index.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (tailwind-shades-for-custom-colors) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

About

This is a Tailwind plugin for automatically generating shades for your custom colors defined under theme.extend.colors in the tailwind.config.js file.

Usage

  1. Install the package:
    npm install tailwind-shades-for-custom-colors


  2. Register the plugin on your tailwind.config.js file:
     
     module.exports  = {
     content: {
         relative: true,
         files: ['./public/index.html']
     },
     theme: {
         extend: {},
     },
     plugins: [require("tailwind-shades-for-custom-colors")]
    }
     
    


  3. Define your custom colors in hex format:
     
     module.exports  = {
        content: {
       relative: true,
       files: ['./public/index.html']
        },
        theme: {
       extend: {
           colors: {
               avocado: "#8df1ab"
           }
       },
        },
        plugins: [require("tailwind-shades-for-custom-colors")]
    }
     
    


  4. Enjoy :)
    
     <h1 class="text-avocado-100">
         Hello world!
     </h1>