fix: Rename use-auth.js to use-auth.jsx for JSX support

This commit is contained in:
Claude committed 2025-11-23 09:24:05 +00:00
1 parent 1dd6d4dae1
commit 1dcb2849e2
2875 files changed
+459559 -2

No files matched your search

+21
View File
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2021 Dany Castillo
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+38
View File
@@ -0,0 +1,38 @@
<!-- This file is autogenerated. If you want to change this content, please do the changes in `./docs/README.md` instead. -->
<div align="center">
<br />
<a href="https://github.com/dcastil/tailwind-merge">
<img src="https://github.com/dcastil/tailwind-merge/raw/v3.4.0/assets/logo.svg" alt="tailwind-merge" height="150px" />
</a>
</div>
# tailwind-merge
Utility function to efficiently merge [Tailwind CSS](https://tailwindcss.com) classes in JS without style conflicts.
```ts
import { twMerge } from 'tailwind-merge'
twMerge('px-2 py-1 bg-red hover:bg-dark-red', 'p-3 bg-[#B91C1C]')
// → 'hover:bg-dark-red p-3 bg-[#B91C1C]'
```
- Supports Tailwind v4.0 up to v4.1 (if you use Tailwind v3, use [tailwind-merge v2.6.0](https://github.com/dcastil/tailwind-merge/tree/v2.6.0))
- Works in all modern browsers and maintained Node versions
- Fully typed
- [Check bundle size on Bundlephobia](https://bundlephobia.com/package/tailwind-merge)
## Get started
- [What is it for](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/what-is-it-for.md)
- [When and how to use it](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/when-and-how-to-use-it.md)
- [Features](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/features.md)
- [Limitations](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/limitations.md)
- [Configuration](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/configuration.md)
- [Recipes](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/recipes.md)
- [API reference](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/api-reference.md)
- [Writing plugins](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/writing-plugins.md)
- [Versioning](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/versioning.md)
- [Contributing](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/contributing.md)
- [Similar packages](https://github.com/dcastil/tailwind-merge/tree/v3.4.0/docs/similar-packages.md)
+93
View File
@@ -0,0 +1,93 @@
{
"name": "tailwind-merge",
"version": "3.4.0",
"description": "Merge Tailwind CSS classes without style conflicts",
"keywords": [
"tailwindcss",
"tailwind",
"css",
"classes",
"className",
"classList",
"merge",
"conflict",
"override"
],
"homepage": "https://github.com/dcastil/tailwind-merge",
"bugs": {
"url": "https://github.com/dcastil/tailwind-merge/issues"
},
"funding": {
"type": "github",
"url": "https://github.com/sponsors/dcastil"
},
"license": "MIT",
"author": "Dany Castillo",
"files": [
"dist",
"src"
],
"source": "src/index.ts",
"exports": {
".": {
"types": "./dist/types.d.ts",
"require": "./dist/bundle-cjs.js",
"import": "./dist/bundle-mjs.mjs",
"default": "./dist/bundle-mjs.mjs"
},
"./es5": {
"types": "./dist/types.d.ts",
"require": "./dist/es5/bundle-cjs.js",
"import": "./dist/es5/bundle-mjs.mjs",
"default": "./dist/es5/bundle-mjs.mjs"
}
},
"main": "./dist/bundle-cjs.js",
"types": "./dist/types.d.ts",
"repository": {
"type": "git",
"url": "https://github.com/dcastil/tailwind-merge.git"
},
"sideEffects": false,
"scripts": {
"build": "rollup --config scripts/rollup.config.mjs",
"bench": "vitest bench --config scripts/vitest.config.mts --no-watch",
"test": "vitest --config scripts/vitest.config.mts --no-watch --coverage",
"test:watch": "vitest --config scripts/vitest.config.mts",
"test:exports": "node scripts/test-built-package-exports.cjs && node scripts/test-built-package-exports.mjs",
"lint": "eslint --max-warnings 0 '**'",
"preversion": "if [ -n \"$DANYS_MACHINE\" ]; then git checkout main && git pull; fi",
"version": "zx scripts/update-readme.mjs",
"postversion": "if [ -n \"$DANYS_MACHINE\" ]; then git push --follow-tags && open https://github.com/dcastil/tailwind-merge/releases; fi"
},
"dependencies": {},
"devDependencies": {
"@babel/core": "^7.28.4",
"@babel/preset-env": "^7.28.3",
"@codspeed/vitest-plugin": "^5.0.1",
"@rollup/plugin-babel": "^6.0.4",
"@rollup/plugin-node-resolve": "^16.0.1",
"@rollup/plugin-typescript": "^12.1.4",
"@types/node": "^24.9.2",
"@vitest/coverage-v8": "^3.2.4",
"@vitest/eslint-plugin": "^1.3.15",
"babel-plugin-annotate-pure-calls": "^0.5.0",
"babel-plugin-polyfill-regenerator": "^0.6.5",
"eslint": "^9.37.0",
"eslint-plugin-import": "^2.32.0",
"globby": "^11.1.0",
"prettier": "^3.6.2",
"rollup": "^4.52.4",
"rollup-plugin-delete": "^3.0.1",
"rollup-plugin-dts": "^6.2.3",
"tslib": "^2.8.1",
"typescript": "^5.9.3",
"typescript-eslint": "^8.45.0",
"vitest": "^3.2.4",
"zx": "^8.8.4"
},
"publishConfig": {
"provenance": true
},
"packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e"
}
+17
View File
@@ -0,0 +1,17 @@
export { createTailwindMerge } from './lib/create-tailwind-merge'
export { getDefaultConfig } from './lib/default-config'
export { extendTailwindMerge } from './lib/extend-tailwind-merge'
export { fromTheme } from './lib/from-theme'
export { mergeConfigs } from './lib/merge-configs'
export { twJoin, type ClassNameValue } from './lib/tw-join'
export { twMerge } from './lib/tw-merge'
export {
type ClassValidator,
type Config,
type ConfigExtension,
type DefaultClassGroupIds,
type DefaultThemeGroupIds,
type ExperimentalParseClassNameParam,
type ParsedClassName as ExperimentalParsedClassName,
} from './lib/types'
export * as validators from './lib/validators'