1 | [![@nuxtjs/tailwindcss](https://tailwindcss.nuxtjs.org/preview.png)](https://tailwindcss.nuxtjs.org)
|
2 |
|
3 | # @nuxtjs/tailwindcss
|
4 |
|
5 | [![npm version][npm-version-src]][npm-version-href]
|
6 | [![npm downloads][npm-downloads-src]][npm-downloads-href]
|
7 | [![Github Actions CI][github-actions-ci-src]][github-actions-ci-href]
|
8 | [![Codecov][codecov-src]][codecov-href]
|
9 | [![License][license-src]][license-href]
|
10 |
|
11 | > [Tailwind CSS](https://tailwindcss.com) module for [NuxtJS](https://nuxtjs.org) with [modern css](https://tailwindcss.com/docs/using-with-preprocessors#future-css-features) âĄī¸
|
12 |
|
13 | - [⨠Release Notes](https://tailwindcss.nuxtjs.org/releases)
|
14 | - [đ Documentation](https://tailwindcss.nuxtjs.org)
|
15 |
|
16 | ## Features
|
17 |
|
18 | - đ Zero configuration to start *([see video](https://tailwindcss.nuxtjs.org/#quick-start))*
|
19 | - đ PurgeCSS included for minimal CSS âĄī¸
|
20 | - âĄī¸ Supports [Tailwind Just-In-Time](https://github.com/tailwindlabs/tailwindcss-jit)
|
21 | - đĒ Includes [PostCSS Nested](https://github.com/postcss/postcss-nested)
|
22 | - đ¨ Discover your Tailwind Colors *([see video](https://tailwindcss.nuxtjs.org/#tailwind-colors))*
|
23 | - âī¸ Reference your Tailwind config in your app
|
24 | - đĻ Extendable by [Nuxt modules](https://modules.nuxtjs.org/)
|
25 |
|
26 | [đ Read more](https://tailwindcss.nuxtjs.org)
|
27 |
|
28 | ## Quick Setup
|
29 |
|
30 | 1. Add `@nuxtjs/tailwindcss` dependency to your project
|
31 |
|
32 | ```bash
|
33 | # Using npm
|
34 | npm install --save-dev @nuxtjs/tailwindcss
|
35 | # Using yarn
|
36 | yarn add --dev @nuxtjs/tailwindcss
|
37 | ```
|
38 |
|
39 | 2. Add `@nuxtjs/tailwindcss` to the `buildModules` section of `nuxt.config.js`
|
40 |
|
41 | ```js
|
42 | {
|
43 | buildModules: [
|
44 | '@nuxtjs/tailwindcss'
|
45 | ]
|
46 | }
|
47 | ```
|
48 |
|
49 | âšī¸ If you are using `nuxt < 2.9.0`, use `modules` property instead.
|
50 |
|
51 | That's it! You can now use Tailwind classes in your Nuxt app â¨
|
52 |
|
53 | [đ Read more](https://tailwindcss.nuxtjs.org/setup)
|
54 |
|
55 | ## Contributing
|
56 |
|
57 | You can contribute to this module online with CodeSandBox:
|
58 |
|
59 | [![Edit @nuxtjs/tailwindcss](https://codesandbox.io/static/img/play-codesandbox.svg)](https://codesandbox.io/s/github/nuxt-community/tailwindcss-module/tree/main/?fontsize=14&hidenavigation=1&theme=dark)
|
60 |
|
61 | Or locally:
|
62 |
|
63 | 1. Clone this repository
|
64 | 2. Install dependencies using `yarn install` or `npm install`
|
65 | 3. Start development server using `yarn dev` or `npm run dev`
|
66 |
|
67 | ## License
|
68 |
|
69 | [MIT License](./LICENSE)
|
70 |
|
71 | Copyright (c) Nuxt.js Team
|
72 |
|
73 |
|
74 | [npm-version-src]: https://img.shields.io/npm/v/@nuxtjs/tailwindcss/latest.svg
|
75 | [npm-version-href]: https://npmjs.com/package/@nuxtjs/tailwindcss
|
76 |
|
77 | [npm-downloads-src]: https://img.shields.io/npm/dt/@nuxtjs/tailwindcss.svg
|
78 | [npm-downloads-href]: https://npmjs.com/package/@nuxtjs/tailwindcss
|
79 |
|
80 | [github-actions-ci-src]: https://github.com/nuxt-community/tailwindcss-module/workflows/ci/badge.svg
|
81 | [github-actions-ci-href]: https://github.com/nuxt-community/tailwindcss-module/actions?query=workflow%3Aci
|
82 |
|
83 | [codecov-src]: https://img.shields.io/codecov/c/github/nuxt-community/tailwindcss-module.svg
|
84 | [codecov-href]: https://codecov.io/gh/nuxt-community/tailwindcss-module
|
85 |
|
86 | [license-src]: https://img.shields.io/npm/l/@nuxtjs/tailwindcss.svg
|
87 | [license-href]: https://npmjs.com/package/@nuxtjs/tailwindcss
|