Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/bly-th/tailwind-custom-utilities
https://github.com/bly-th/tailwind-custom-utilities
Last synced: 8 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/bly-th/tailwind-custom-utilities
- Owner: bly-th
- License: mit
- Created: 2023-02-14T10:43:05.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-02-14T12:14:59.000Z (almost 2 years ago)
- Last Synced: 2024-04-26T03:01:10.946Z (7 months ago)
- Language: JavaScript
- Size: 603 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# 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:
```js
// 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:
```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](https://github.com/Landish/create-tailwind-plugin).