# tailwindcss-icons

> Svg icon utilities for tailwindcss

Latest version **1.0.2** (published 2022-04-02) · ISC license · 0 weekly downloads

## Install

```sh
npm install tailwindcss-icons
pnpm add tailwindcss-icons
yarn add tailwindcss-icons
bun add tailwindcss-icons
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2022-04-02 |
| First published | 2022-02-24 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 4.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Maintainers | martk |

## Links

- npm: https://www.npmjs.com/package/tailwindcss-icons
- npm.io page: https://npm.io/package/tailwindcss-icons

## Dependencies (1)

- [glob](https://npm.io/package/glob.md) ^7.2.0

## Recent versions

- 1.0.2 (latest) — 2022-04-02
- 1.0.1 — 2022-02-24
- 1.0.0 — 2022-02-24

## README

## Svg icons utilities for tailwindcss

Usage:

```js
const { tailwindcssIcons, createIconBuilder } = require('tailwindcss-icons');

module.exports = {
	plugins: [
		tailwindcssIcons(path.join(__dirname, 'icons'), true, createIconBuilder('icon')),
	]
};
```

Add placeholder %color% to svg icon in icons/example.svg
```svg
<svg xmlns="http://www.w3.org/2000/svg" width="12" height="12.001" viewBox="0 0 12 12.001">
	<path fill="%color%" fill-rule="evenodd" d="M340.293 148.293a1 1 0 0 1 1.414 0l4.293 4.293 4.293-4.293a1 1 0 0 1 1.414 1.414L347.414 154l4.293 4.293a1 1 0 0 1-1.414 1.414L346 155.414l-4.293 4.293a1 1 0 0 1-1.414-1.414l4.293-4.293-4.293-4.293a1 1 0 0 1 0-1.414z" transform="translate(-340 -148)"/>
</svg>
```

Pattern for html: %prefix%-%name%-%color%

Usage in html for icon in icons/example.svg
```html
<span class="icon-example-black"></span>
<span class="icon-example-white"></span>
```

Usage in html for icon in icons/brands/fb.svg
```html
<span class="icon-brands--fb-white"></span>
<span class="icon-brands--fb-black"></span>
```

Known issues:
- When added new icon, restart builder

---
_Source: https://npm.io/package/tailwindcss-icons · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
