
tailwindcss
Go to documentationAdd Tailwind CSS to your Nuxt application in seconds with PurgeCSS included for minimal CSS.
v6.7.0 by
Atinux
What's Changed
- feat: allow content as object by @ineshbose in nuxt-modules/tailwindcss#674
- docs: mention plugins in editor support by @ineshbose in nuxt-modules/tailwindcss#675
- fix(vite-plugin): consider content as object by @ineshbose in nuxt-modules/tailwindcss#672
- fix: srcDir for layers by @ineshbose in nuxt-modules/tailwindcss#676
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.8...v6.7.0
v6.6.8 by
Atinux
What's Changed
- fix: no longer generate .nuxt/tailwind.config.cjs by @P4sca1 in nuxt-modules/tailwindcss#660
- fix: add minimatch and fix the error with no exported default
- chore(deps): update dependency cookie-es to v1 by @renovate in nuxt-modules/tailwindcss#669
- chore(deps): update devdependency jsdom to v22 by @renovate in nuxt-modules/tailwindcss#667
- docs: content overriding with test files by @ineshbose in nuxt-modules/tailwindcss#670
- chore(deps): update all non-major dependencies by @renovate in nuxt-modules/tailwindcss#645
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.7...v6.6.8
v6.6.7 by
Atinux
What's Changed
- Exclude test files and add app.config from glob pattern by @maartenvanhunsel in nuxt-modules/tailwindcss#662
- test: fix test by @antfu in nuxt-modules/tailwindcss#665
New Contributors
- @maartenvanhunsel made their first contribution in nuxt-modules/tailwindcss#662
- @antfu made their first contribution in nuxt-modules/tailwindcss#665
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.6...v6.6.7
v6.6.6 by
Atinux
What's Changed
- fix viewer by @asc0910 in nuxt-modules/tailwindcss#658
- chore(module): call hook before resolving config by @benjamincanac in nuxt-modules/tailwindcss#655
New Contributors
- @asc0910 made their first contribution in nuxt-modules/tailwindcss#658
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.5...v6.6.6
v6.6.5 by
danielroe
What's Changed
- chore(deps): update to tailwind 3.3.0 by @owlnai in nuxt-modules/tailwindcss#651
- fix: typeof import default in dts by @ineshbose in nuxt-modules/tailwindcss#647
New Contributors
- @owlnai made their first contribution in nuxt-modules/tailwindcss#651
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.4...v6.6.5
v6.6.4 by
Atinux
What's Changed
- fix: use file extension (for esm support) and add missing deps by @danielroe in nuxt-modules/tailwindcss#644
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.3...v6.6.4
v6.6.3 by
Atinux
v6.6.2 by
Atinux
What's Changed
- chore: using tw default config by @ineshbose in nuxt-modules/tailwindcss#636
- fix viewer endpoint route url by @czak-dev in nuxt-modules/tailwindcss#642
New Contributors
- @czak-dev made their first contribution in nuxt-modules/tailwindcss#642
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.1...v6.6.2
v6.6.1 by
Atinux
What's Changed
- chore: reducing dependencies by @ineshbose in nuxt-modules/tailwindcss#634
- chore: update readme by @ineshbose in nuxt-modules/tailwindcss#640
- chore: move heavy populateMap function to utils by @ineshbose in nuxt-modules/tailwindcss#637
- chore: add
utils
to default content path by @manniL in nuxt-modules/tailwindcss#641 - chore: improving types for config by @ineshbose in nuxt-modules/tailwindcss#635
- chore(deps): update all non-major dependencies by @renovate in nuxt-modules/tailwindcss#631
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.6.0...v6.6.1
v6.6.0 by
Atinux
What's Changed
- feat: restart Nuxt server on config changes (Nuxt >= 3.3) by @Atinux in nuxt-modules/tailwindcss#624
- feat(exposeConfig): maximize nested exports by @ineshbose in nuxt-modules/tailwindcss#629
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.5.0...v6.6.0
v6.5.0 by
Atinux
What's Changed
- feat: providing types for all exports by @ineshbose in nuxt-modules/tailwindcss#617
- fix: set preset plugins to null in resolved config by @tkofh in nuxt-modules/tailwindcss#618
- chore(deps): update all non-major dependencies by @renovate in nuxt-modules/tailwindcss#615
- docs: broken links updated by @zackha in nuxt-modules/tailwindcss#625
New Contributors
- @zackha made their first contribution in nuxt-modules/tailwindcss#625
- @tkofh made their first contribution in nuxt-modules/tailwindcss#618
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.4.1...v6.5.0
v6.4.0 by
Atinux
What's Changed
- Adding Tailwind Viewer to Nuxt Devtools by @claranceliberi in nuxt-modules/tailwindcss#612

- Support for nuxt 2.16+ by @simllll in nuxt-modules/tailwindcss#611
- docs: add example for flowbite in nuxt-modules/tailwindcss#605
- chore(deps): update all non-major dependencies by @renovate in nuxt-modules/tailwindcss#604
New Contributors
- @simllll made their first contribution in nuxt-modules/tailwindcss#611
- @claranceliberi made their first contribution in nuxt-modules/tailwindcss#612
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.3.1...v6.4.0
v6.3.0 by
Atinux
What's Changed
Features ✨
- Expose nested properties by @ineshbose in nuxt-modules/tailwindcss#583, learn more.
Fixes 🐞
- fix: considered content as function by @ineshbose in nuxt-modules/tailwindcss#592
- fix: css intellisense not working by @nazar1ua in nuxt-modules/tailwindcss#596
Chores 🧹
- chore(deps): update dependency postcss-nesting to v11 by @renovate in nuxt-modules/tailwindcss#600
- chore(deps): update devdependency jsdom to v21 by @renovate in nuxt-modules/tailwindcss#588
- chore(deps): update dependency ufo to v1 by @renovate in nuxt-modules/tailwindcss#564
- chore(deps): update dependency postcss-custom-properties to v13 by @renovate in nuxt-modules/tailwindcss#599
New Contributors
- @nazar1ua made their first contribution in nuxt-modules/tailwindcss#596
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.2.0...v6.3.0
v6.1.3 by
Atinux
What's Changed
- fix: css option in object format error (Nuxt 2). by @mena234 in nuxt-modules/tailwindcss#557
- docs: Brackets missing in the
nuxt.config.ts
. by @boring-dragon in nuxt-modules/tailwindcss#556
New Contributors
- @boring-dragon made their first contribution in nuxt-modules/tailwindcss#556
- @mena234 made their first contribution in nuxt-modules/tailwindcss#557
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.1.2...v6.1.3
v6.1.1 by
Atinux
What's Changed
- fix:
cjs
config generation by @ExEr7um in nuxt-modules/tailwindcss#551
New Contributors
- @ExEr7um made their first contribution in nuxt-modules/tailwindcss#551
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.1.0...v6.1.1
v6.1.0 by
Atinux
What's Changed
- feat: add option to set
cssPath
tofalse
by @younho9 in nuxt-modules/tailwindcss#544
New Contributors
- @younho9 made their first contribution in nuxt-modules/tailwindcss#544
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.0.1...v6.1.0
v6.0.1 by
Atinux
What's Changed
- Upgrade Tailwind to v3.2 and other dependencies
- docs: Improve documentation for tailwind config and allow tailwind.config.cjs by @P4sca1 in nuxt-modules/tailwindcss#550
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v6.0.0...v6.0.1
v6.0.0 by
Atinux
What's Changed
Now Compatible with Nuxt RC12.
- feat!: update viewer dev middleware to be compatible with
h3@0.8
by @DamianGlowala in nuxt-modules/tailwindcss#545 - feat: expose config as commonjs file by @tobiasdiez in nuxt-modules/tailwindcss#535
- docs: Update setup.md by @nick-wireless in nuxt-modules/tailwindcss#538
- docs: Mentioning the need of adding Tailwind directives by @MrMohamedAbdallah in nuxt-modules/tailwindcss#546
- chore: update to rc12 by @IsraelOrtuno in nuxt-modules/tailwindcss#548
New Contributors
- @nick-wireless made their first contribution in nuxt-modules/tailwindcss#538
- @MrMohamedAbdallah made their first contribution in nuxt-modules/tailwindcss#546
- @IsraelOrtuno made their first contribution in nuxt-modules/tailwindcss#548
- @tobiasdiez made their first contribution in nuxt-modules/tailwindcss#535
Full Changelog: https://github.com/nuxt-modules/tailwindcss/compare/v5.3.5...v6.0.0
v5.3.2 by
Atinux
What's Changed
- fix: remove now-unneeded
@types/tailwindcss
by @genu in #514 - fix(module): remove prefix for tailwind viewer route on nuxt 2 by @chettapong in #517
New Contributors
- @genu made their first contribution in #514
- @chettapong made their first contribution in #517
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.3.1...v5.3.2
v5.3.1 by
Atinux
v5.3.0 by
Atinux
What's Changed
- feat: extends support by @Tahul in #499
- feat: support for more semantic injection positions by @makkarpov in #501
- docs: add editor support section by @P4sca1 in #502
- chore(deps): update all non-major dependencies by @renovate in #486
New Contributors
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.2.0...v5.3.0
v5.2.0 by
Atinux
What's Changed
- feat: add
tailwind.config.ts
support by @harlan-zw in #483, learn more - fix: monkey-patch Vite HMR issue & make it reproducible (#464) by @makkarpov in #496
- docs: update options.md by @DarraghOFlaherty in #494
New Contributors
- @harlan-zw made their first contribution in #483
- @DarraghOFlaherty made their first contribution in #494
- @makkarpov made their first contribution in #496
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.1.3...v5.2.0
v5.1.3 by
Atinux
What's Changed
The tailwind viewer should now work again and the documentation has been updated with Nuxt 3 ❤️
- fix: add prefix for tailwind viewer route by @chenly in #460
- docs: upgrade docus by @smarroufin in #485
- docs: update logo & social preview by @smarroufin in #492
- docs: remove
nuxt.config.{js, ts}
from content array by @dammy001 in #489
New Contributors
- @smarroufin made their first contribution in #485
- @dammy001 made their first contribution in #489
- @chenly made their first contribution in #460
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.1.2...v5.1.3
v5.1.2 by
Atinux
Bug Fixes
- use correct defuArrayFn and fix srcDir error (cef3a9f)
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.1.1...v5.1.2
v5.1.1 by
Atinux
What's Changed
- fix(content): Add support for error file by @sasial-dev in #467
New Contributors
- @sasial-dev made their first contribution in #467
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.1.0...v5.1.1
v5.1.0 by
Atinux
What's Changed
- feat: resolve
cssPath
withresolvePath
by @dcrall in #465 - chore(deps): update all non-major dependencies by @renovate in #441
- chore(deps): update actions/cache action to v3 by @renovate in #445
- chore(deps): update dependency defu to v6 by @renovate in #446
- docs: fix typo by @jiblett1000 in #468
- docs: changed deprecated buildModules to modules by @N1kl8s in #473
- chore: upgrade to rc3 by @DamianGlowala in #477
- chore(deps): update all non-major dependencies by @renovate in #476
New Contributors
- @jiblett1000 made their first contribution in #468
- @N1kl8s made their first contribution in #473
- @dcrall made their first contribution in #465
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.0.4...v5.1.0
v5.0.4 by
Atinux
What's Changed
- docs: general review of all sections by @DamianGlowala in #461
- fix: add tailwindcss types by @yassilah in #462
New Contributors
- @DamianGlowala made their first contribution in #461
- @yassilah made their first contribution in #462
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.0.3...v5.0.4
v5.0.3 by
Atinux
What's Changed
- docs: update config.md by @Rigo-m in #457
- docs: Fix tailwind.config.ts url in docs by @guillaumebriday in #450
- fix: tailwind viewer url by @shba007 in #453
New Contributors
- @Rigo-m made their first contribution in #457
- @guillaumebriday made their first contribution in #450
- @shba007 made their first contribution in #453
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v5.0.2...v5.0.3
v5.0.0 by
Atinux
Stable version is out and ready for feedback 🎊
Please read carefully the v5.0.0-0 release notes.
What's included
- Update Setup Docs by @juliangeissler in #374
- docs: Add note about using resolved config with TypeScript by @disusered in #396
- feat: add css inject position by @yolofit in #381
- chore(deps): update devdependency eslint to v8 by @renovate in #391
- chore(deps): update devdependency @types/jest to v27 by @renovate in #375
- chore(deps): update dependency postcss-custom-properties to v12 by @renovate in #383
- feat: migrate to tailwind v3 by @dargmuesli in #407
- docs: fix brand to
Tailwind CSS
by @hmaesta in #417 - chore(deps): update all non-major dependencies by @renovate in #400
- docs: add missing viewer option by @LeCoupa in #412
- refactor!: rewrite with module-builder and nuxt/kit by @pi0 in #419
- chore(deps): update all non-major dependencies by @renovate in #422
- fix: import
tailwindcss/resolveConfig
with extension by @Ricklin90085 in #426 - chore(deps): update all non-major dependencies by @renovate in #427
- chore(deps): update actions/setup-node action to v3 by @renovate in #435
New Contributors
- @juliangeissler made their first contribution in #374
- @disusered made their first contribution in #396
- @yolofit made their first contribution in #381
- @dargmuesli made their first contribution in #407
- @hmaesta made their first contribution in #417
- @LeCoupa made their first contribution in #412
Full Changelog: https://github.com/nuxt-community/tailwindcss-module/compare/v4.2.1...v5.0.0
Nuxt 3 and Tailwind CSS 3 support by
pi0
This is a prerelease
You can try v5 by installing @nuxtjs/tailwindcss@5.0.0-4
with the package manager of your choice.
🐛 Some bugs are expected with this release. Please open an issue if had trouble with v5 upgrade.
⚠ BREAKING CHANGES
- Nuxt 3 is supported
- TailwindCSS upgraded to v3 (thanks to PR by @dargmuesli 💚 ). Read more about changes in Tailwind upgrade guide.
- JIT mode is enabled by default. You can remove
jit
option if was already using ~tailwind.config
import renamed to#tailwind-config
when importing the generated Tailwind config in the application- (Module authors)
tailwindcss:config
hook is being called when modules are being installed for more predictable building behavior. Any module extending tailwind config should be installed before tailwindcss module
Features
v4.2.1 by
Atinux
- fix: specify files to avoid rootDir watcher (#370)
v4.2.0 by
Atinux
v4.1.3 by
Atinux
Fixes
- fix: add ts extension for purging components folder (#356) · 8328c52
- fix incorrect link (bottom right) (#353) · dd45c32
Dependencies
- chore(deps): update dependency defu to v5 (#346) · e5f8f02
- chore(deps): update devdependency jest to v27 (#355) · [
89382fc
](https://github.com/nuxt-community/tailwindcss-
Documentation
v4.1.2 by
Atinux
v4.1.1 by
Atinux
- Remove
@tailwindcss/jit
dependency (#340)
v4.0.3 by
Atinux
v4.0.1 by
Atinux
Switch from postcss-nested to postcss-nesting to respect CSS Nesting spec we supported with version 3 of the module.
v4.0.0 by
Atinux
Tailwind 2 with PostCSS 8
PostCSS 8 is now possible thanks to @nuxt/postcss8! No more compatibility build to use the latest version of Tailwind now ✨
Make sure to read the installation steps.
Tailwind Just-In-Time
You may have heard about the Just-In-Time compilation mode of TailwindCSS, this version supports it, simply set the jit
option in your nuxt.config.js
:
export default { buildModules: ['@nuxtjs/tailwindcss'], tailwindcss: { jit: true }}
With jit
option, our build on nuxtjs.org came from 40s to 7s ⚡
v3.4.3 by
pi0
Bug Fixes
- Use nuxt resolver to import
tailwind.config.js
(#286) (62526cf) (resolves nuxt/nuxt.js#8971)
v3.4.0 by
Atinux
v3.3.4 by
Atinux
v3.3.2 by
Atinux
v3.0.1 by
Atinux
- Upgrade to TailwindCSS 1.7.3
- Docs: add Upgrading Tailwind section
v3.0.0 by
Atinux
⚠ BREAKING CHANGES
build.postcss.plugins
asArray
is not supported anymore
Features
We now have a documentation website: https://tailwindcss.nuxtjs.org
- The module will not create the tailwind files anymore but load them if they exist
@nuxtjs/tailwindcss
now configures the purge option of TailwindCSS and let the user extend it easily to keep a minimaltailwind.config.js
template- Nuxt modules can easily extend the user tailwind config (adding Typography plugin, settings colors, etc)
- Updating the
tailwind.config.js
will actually do a full Nuxt server restart but will actually fix the plugins update issue
v2.1.1 by
Atinux
Upgrade Tailwindcss to v1.6.0
v2.1.0 by
Atinux
Misc ✨
- Upgrade dependencies (TailwindCSS to
v1.5.1
).
If a new version of TailwindCSS goes out, you can always install it with npm install --save-dev tailwindcss
, the module will use it directly.
Bug fixes 🐞
- Force production env for postcss on
nuxt build
(977d605
)
v2.0.0 by
Atinux
Version 2.0 is out, including TailwindCSS v1.4 ✨
This version is a breaking change since we actually removed nuxt-purgecss
dependency, since Tailwind 1.4 has a purge option now!
If you are upgrading, take a look at the new tailwind.config.js
:
// tailwind.config.jsmodule.exports = { /* ... your actual config */, purge: { // Learn more on https://tailwindcss.com/docs/controlling-file-size/#removing-unused-css enabled: process.env.NODE_ENV === 'production', content: [ 'components/**/*.vue', 'layouts/**/*.vue', 'pages/**/*.vue', 'plugins/**/*.js', 'nuxt.config.js' ] }}
v1.4.1 by
Atinux
- Upgrade dependencies and use Tailwind
v1.3.4
✨
v1.4.0 by
Atinux
Features
- Add
exposeConfig
option to reference resolved config in javascript runtime (PR #69)
See demo and source code
Chore
- Upgrade dependencies
v1.3.3 by
Atinux
- Fix: don't purge base and components (#65 by @hecktarzuli)
- Upgrade dependencies (#63)
v1.3.1 by
Atinux
v1.3.0 by
Atinux
- Upgrade TailwindCSS to
v1.1.4
- Add
purgeCSSInDev
option to activate purgeCSS in development mode
v1.2.0 by
Atinux
- Upgrade TailwindCSS to
1.1.3
- Add support for deprecated
build.postcss.plugins
syntax (#36)
v1.1.2 by
Atinux
v0.1.1 by
Atinux
See changelog
v0.1.0 by
Atinux
See changelog
v0.0.4 by
Atinux
See changelog