Skip to content

Commit

Permalink
docs: add tailwind
Browse files Browse the repository at this point in the history
  • Loading branch information
typicode committed Feb 27, 2024
1 parent 87996b9 commit 5a1ea0a
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,9 @@ export default function App() {
<Button size="lg" danger>
OMG 😱 JS from CSS
</Button>
<Button size="large">Submit</Button> {/* 💥 TypeScript will catch the error here */}

{/* 💥 TypeScript will catch the error here */}
<Button size="large">Submit</Button>
</main>
)
}
Expand Down Expand Up @@ -123,6 +125,18 @@ Edit `.vscode/settings.json`:
}
```

### 5. TailwindCSS

If you're using NextJS, you may need to add [support for nested declarations](https://tailwindcss.com/docs/using-with-preprocessors#nesting).

Use Tailwind's `@apply` directive to style your CSS component. For example:

```
&[data-danger] {
@apply bg-red text-white
}
```

## The power of CSS

Since MistCSS uses pure CSS, you can use **all** CSS features:
Expand All @@ -149,7 +163,7 @@ MistCSS is a new project, so expect **breaking changes** until `v1.0`.
If you like this idea and want to help, please consider having your company [sponsor](https://github.com/typicode/mistcss) it 🙇. This project is not backed by a large company.

- [x] Release 🥳
- [ ] Add TailwindCSS support
- [x] Add TailwindCSS support
- [ ] Add Vite support
- [ ] CLI and compiler improvements
- [ ] v1.0

0 comments on commit 5a1ea0a

Please sign in to comment.