Skip to content

Commit 17fed25

Browse files
committed
Merge branch 'main' into bronisMateusz/main
2 parents 779e2ea + db0bd74 commit 17fed25

27 files changed

+5722
-4406
lines changed

.github/FUNDING.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
custom: ['https://tailwindcss.com/sponsor']

CHANGELOG.md

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## [Unreleased]
99

10-
- Nothing yet!
10+
- Don't augment global Prettier `ParserOptions` and `RequiredOptions` types ([#354](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/354))
11+
- Drop support for `prettier-plugin-import-sort` ([#385](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/385))
12+
- Format quotes in `@source`, `@plugin`, and `@config` ([#387](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/387))
13+
- Support sorting in callable template literals ([#367](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/367))
14+
- Support sorting in function calls mixed with property accesses ([#367](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/367))
15+
16+
## [0.6.14] - 2025-07-09
17+
18+
- Add support for OXC + Hermes Prettier plugins ([#376](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/376), [#380](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/380))
19+
- Sort template literals in Angular expressions ([#377](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/377))
20+
- Don't repeatedly add backslashes to escape sequences when formatting ([#381](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/381))
21+
22+
## [0.6.13] - 2025-06-19
23+
24+
- Prevent Svelte files from breaking when there are duplicate classes ([#359](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/359))
25+
- Ensure `prettier-plugin-multiline-arrays` and `prettier-plugin-jsdoc` work when used together with this plugin ([#372](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/372))
26+
27+
## [0.6.12] - 2025-05-30
28+
29+
- Add internal (unsupported) option to load Tailwind CSS using a different package name ([#366](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/366))
1130

1231
## [0.6.11] - 2025-01-23
1332

@@ -353,7 +372,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
353372

354373
- Fix error when using nullish coalescing operator in Vue/Angular ([#2](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/pull/2))
355374

356-
[unreleased]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.11...HEAD
375+
[unreleased]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.14...HEAD
376+
[0.6.14]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.13...v0.6.14
377+
[0.6.13]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.12...v0.6.13
378+
[0.6.12]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.11...v0.6.12
357379
[0.6.11]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.10...v0.6.11
358380
[0.6.10]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.9...v0.6.10
359381
[0.6.9]: https://github.com/tailwindlabs/prettier-plugin-tailwindcss/compare/v0.6.8...v0.6.9

README.md

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,24 @@ Then add the plugin to your [Prettier configuration](https://prettier.io/docs/en
1919
}
2020
```
2121

22+
When using a JavaScript config, you can import the types for IntelliSense:
23+
24+
```js
25+
// prettier.config.js
26+
27+
/** @type {import('prettier').Config & import('prettier-plugin-tailwindcss').PluginOptions} */
28+
export default {
29+
plugins: ["prettier-plugin-tailwindcss"],
30+
}
31+
```
32+
2233
## Upgrading to v0.5.x
2334

2435
As of v0.5.x, this plugin now requires Prettier v3 and is ESM-only. This means it cannot be loaded via `require()`. For more information see our [upgrade guide](https://github.com/tailwindlabs/prettier-plugin-tailwindcss/issues/207#issuecomment-1698071122).
2536

2637
## Options
2738

28-
### Specifying your Tailwind stylesheet path
39+
### Specifying your Tailwind stylesheet path (Tailwind CSS v4+)
2940

3041
When using Tailwind CSS v4 you must specify your CSS file entry point, which includes your theme, custom utilities, and other Tailwind configuration options. To do this, use the `tailwindStylesheet` option in your Prettier configuration.
3142

@@ -38,7 +49,7 @@ Note that paths are resolved relative to the Prettier configuration file.
3849
}
3950
```
4051

41-
### Specifying your Tailwind JavaScript config path
52+
### Specifying your Tailwind JavaScript config path (Tailwind CSS v3)
4253

4354
To ensure that the class sorting takes into consideration any of your project's Tailwind customizations, it needs access to your [Tailwind configuration file](https://tailwindcss.com/docs/configuration) (`tailwind.config.js`).
4455

@@ -215,7 +226,6 @@ This plugin uses Prettier APIs that can only be used by one plugin at a time, ma
215226
- `@trivago/prettier-plugin-sort-imports`
216227
- `prettier-plugin-astro`
217228
- `prettier-plugin-css-order`
218-
- `prettier-plugin-import-sort`
219229
- `prettier-plugin-jsdoc`
220230
- `prettier-plugin-multiline-arrays`
221231
- `prettier-plugin-organize-attributes`

0 commit comments

Comments
 (0)