@bly-th/tailwind-custom-utilities

1.0.5 • Public • Published

tailwind-custom-utilities

Generates custom utility classes

Install the plugin from npm:

$ npm install tailwind-custom-utilities

Then add the plugin to your tailwind.config.js file:

// tailwind.config.js
module.exports = {
  theme: {
    // ...
    // Optional. Your plugin might not have any options at all.
    customUtilities: {
      // ...
      YOUR_PLUGIN_CUSTOM_OPTION: true,
      // ...
    },
  },
  variants: {
    // ...
    // Optional. Your plugin might not have any variants at all.
    customUtilities: ['responsive'],
    // ...
  },
  plugins: [
    // ...
    require('tailwind-custom-utilities'),
    // ...
  ],
};

This plugin will generate following CSS:

/* ... */
.example-utility-class {
  display: block;
}

.custom-utility-class {
  background-color: red;
}
/* ... */

License

tailwind-custom-utilities is licensed under the MIT License.

Credits

Created with create-tailwind-plugin.

Package Sidebar

Install

npm i @bly-th/tailwind-custom-utilities

Weekly Downloads

4

Version

1.0.5

License

MIT

Unpacked Size

8.5 kB

Total Files

9

Last publish

Collaborators

  • ryangittings