NewYour coding agent can read the release notes before it upgrades.Set up the MCP server →
npm · #1561 most downloaded on npm
Merge Tailwind CSS classes without style conflicts
Last release 13 days ago
13 Sep 2026
Ships on a steady schedule
a new release about every 3 weeks
Nearly every release is documented
notes for 60 of the last 60 stable releases
Nothing withdrawn
no release was ever pulled
5 years old
474 releases · first in 2021
One column per quarter.
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Add support for container query length units in arbitrary values by @LesnoyPudge in https://github.com/dcastil/tailwind-merge/pull/204
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.9.1...v1.10.0
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Fix arbitrary floats not supported in opacity, scale, etc. by @dcastil in https://github.com/dcastil/tailwind-merge/pull/196
opacity-50 opacity-[.025] weren't merged correctly. You might not have noticed since classes with arbitrary values are defined after the default ones in the output stylesheet, but merging it the other way around (opacity-[.025] opacity-50) would have led to a styling bug.isNumber.Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.9.0...v1.9.1
Nothing published for this version
Nothing published for this version
Support decimals in T-shirt sizes by @farreldarian in https://github.com/dcastil/tailwind-merge/pull/189
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.8.1...v1.9.0
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Fix incorrect class group conflicts in grid-related classes by @dcastil in https://github.com/dcastil/tailwind-merge/pull/177
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.8.0...v1.8.1
Thanks to @aniravi24 for sponsoring tailwind-merge! ❤️
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
I deprecated the `join` function and renamed it to `twJoin` to make replacing it via search and replace easier since join is a common function name. Y…
join to twJoin by @dcastil in https://github.com/dcastil/tailwind-merge/pull/161
join function and renamed it to twJoin to make replacing it via search and replace easier since join is a common function name. You don't need to change anything right now, but if you have some spare time, rename join → twJoin in your code since the join function will be removed in the next major release.Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.7.0...v1.8.0
Thanks to @gjtorikian for sponsoring tailwind-merge! ❤️
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Add support for Tailwind CSS v3.2 by @dcastil and @brandonmcconnell in https://github.com/dcastil/tailwind-merge/pull/159
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.6.2...v1.7.0
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
Nothing published for this version
I deprecated the validator isArbitraryWeight and renamed it to isArbitraryNumber to reflect its broader use case. You don't need to change anything ri…
stroke-[3] correctly.isArbitraryWeight and renamed it to isArbitraryNumber to reflect its broader use case. You don't need to change anything right now, but if you have some spare time, rename isArbitraryWeight → isArbitraryNumber in your code since isArbitraryWeight will be removed in the next major release.0.0.0-dev anymore and instead have the version number of the last release, like 1.6.1-dev. That makes it easier for tools like Renovate to understand which package version you're using in case you use dev releases.Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.6.1...v1.6.2
Nothing published for this version
Nothing published for this version
Fix h-min not working by @dcastil in https://github.com/dcastil/tailwind-merge/pull/146
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.6.0...v1.6.1
Nothing published for this version
Nothing published for this version
Nothing published for this version
Add support for arrays as argument by @dcastil in https://github.com/dcastil/tailwind-merge/pull/127
twMerge. That's especially handy for nested conditions.twMerge('…', someBool && ['…', anotherBool && '…'])
join function which is present in the tailwind-merge exports as well. It has the same functionality as clsx but without support for objects as arguments which makes it a little faster.String.prototype.matchAll()Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.5.1...v1.6.0
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Fix arbitrary z-index value not being recognized by @dcastil in https://github.com/dcastil/tailwind-merge/pull/116
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.5.0...v1.5.1
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Added missing ESM types subpath export condition by @scott-lc in https://github.com/dcastil/tailwind-merge/pull/113
types subpath export condition by @scott-lc in https://github.com/dcastil/tailwind-merge/pull/113
nodenext module type introduced in TypeScript 4.7.Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.4.0...v1.5.0
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Optimize runtime performance by using Map by @dcastil in https://github.com/dcastil/tailwind-merge/pull/105
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.3.0...v1.4.0
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Add support for Tailwind v3.1 by @dcastil in https://github.com/dcastil/tailwind-merge/pull/103
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.2.1...v1.3.0
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Fix isArbitraryWeight incorrectly using weight: instead of number: for disambiguation for arbitrary values by @liuqiang1357 in https://github.com/dcas
weight: instead of number: for disambiguation for arbitrary values by @liuqiang1357 in https://github.com/dcastil/tailwind-merge/pull/85Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.2.0...v1.2.1
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Add prefix support by @dcastil in https://github.com/dcastil/tailwind-merge/pull/78
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.1.1...v1.2.0
Thanks to @charkour for sponsoring tailwind-merge! ❤️
Fix TypeScript types not being linked correctly in package.json by @navin-moorthy and @dcastil in https://github.com/dcastil/tailwind-merge/pull/75
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.1.0...v1.1.1
Fix missing arbitrary value support in some class groups by @dcastil in https://github.com/dcastil/tailwind-merge/pull/73
grayscale, invert, sepia, grow, shrink, object-position, shadow, drop-shadow, rotate, skew and transform-originbreak-inside classes being merged incorrectlyoverline, underline-offset, content-nonebg-repeeat → bg-repeatisArbitraryShadow validator"type": "module" from the package.json. I did test the new npm package output in Node and in the browser, but it's hard to account for every possible build system tailwind-merge is used in. If some issues come up with bundling tailwind-merge, please open an issue!Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v1.0.0...v1.1.0
There are no breaking changes in the tailwind-merge types and some breaking changes for a small number of users in the return values, so you should ge…
v1! 🎉
After being 5 months on v0 I think it's time to release a stable version of tailwind-merge. Tailwind v3 was released yesterday and it's no coincidence that I'm releasing tailwind-merge v1 today. I added full support for Tailwind v3 so you can update both at once.
There are no breaking changes in the tailwind-merge types and some breaking changes for a small number of users in the return values, so you should get through smoothly.
By the way, you can now sponsor this project. 😊
twMerge, extendTailwindMerge
overflow-ellipsis and overflow-clip will not get merged with class truncate anymore, but the new Tailwind v3 classes text-ellipsis and text-clip will. (https://github.com/dcastil/tailwind-merge/pull/63/commits/65b03e48914ac5d7d52eea9ec178b204d30609c9, https://github.com/dcastil/tailwind-merge/pull/63)decoration-slice and decoration-clone won't get merged anymore and box-decoration-slide nad box-decoration-clone will (https://github.com/dcastil/tailwind-merge/pull/63/commits/bfe2cc9bb221107fa0bf363cc325ddbb04677f43, https://github.com/dcastil/tailwind-merge/pull/63)getDefaultConfig
outline since it was removed in Tailwind v3 (https://github.com/dcastil/tailwind-merge/pull/63/commits/55ab167b7167519873c5dd4d258dc62212d1659a, https://github.com/dcastil/tailwind-merge/pull/63)vertival-alignment (yes, the typo was in the code) to vertical-align (https://github.com/dcastil/tailwind-merge/pull/63/commits/1269ce68ae39807ceadbecc98c0929fdfdb446d0, https://github.com/dcastil/tailwind-merge/pull/63)flex-basis, flex-grow and flex-shrink to basis, grow and shrink to stay consistent with Tailwind v3 (https://github.com/dcastil/tailwind-merge/pull/63/commits/e6d8912e47bf9a89346b9b0cc822fb2bff2af172, https://github.com/dcastil/tailwind-merge/pull/63)validators
isCustomLength and isCustomValue were renamed to isArbitraryLength and isArbitraryValue to be consistent with naming in Tailwind v3 documentation (https://github.com/dcastil/tailwind-merge/pull/63/commits/adc3c02c7f035069beec1c62777ec008172587ab, https://github.com/dcastil/tailwind-merge/pull/63)[--my-var:20px]![--my-very-important-var: 21px]size, position, url, weight and familyisTshirtSize, isArbitrarySize, isArbitraryPosition, isArbitraryUrl and isArbitraryWeight, check them out in the documentation! (https://github.com/dcastil/tailwind-merge/pull/63/commits/fec2b18870f6806e602009632b52b9fe89ebfb83, https://github.com/dcastil/tailwind-merge/pull/63/commits/f8acd7ca5be6cc40ad4c1cbdee7522bbc44c7870, https://github.com/dcastil/tailwind-merge/pull/63)Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v0.9.0...v1.0.0
Mimic theme from Tailwind config in tailwind-merge config by @dcastil in https://github.com/dcastil/tailwind-merge/pull/55
spacing, borderRadius, etc. More on that in the theme docs.Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v0.8.2...v0.9.0
Fix custom values for list-style-type missing in default config by @dcastil in https://github.com/dcastil/tailwind-merge/pull/53
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v0.8.1...v0.8.2
Fix missing support for custom values in some class groups in default config by @dcastil in https://github.com/dcastil/tailwind-merge/pull/52
Full Changelog: https://github.com/dcastil/tailwind-merge/compare/v0.8.0...v0.8.1
Your coding agent can read these notes before it upgrades. Set up the MCP server →