You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: website/blog/2024-11-26-3.4.0.md
+11-11Lines changed: 11 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -105,8 +105,8 @@ const str = "\a";
105
105
106
106
#### Removed support for experimental syntax ([#16643](https://github.com/prettier/prettier/pull/16643), [#16705](https://github.com/prettier/prettier/pull/16705) by [@fisker](https://github.com/fisker))
107
107
108
-
- `DecimalLiteral` - The [Decimal proposal](https://github.com/tc39/proposal-decimal) decided not introduce new syntax. The `decimal` plugin will be removed from Babel 8.
109
-
- `importReflection` - The "Import Reflection" proposal has renamed as ["Source Phase Imports"](https://github.com/tc39/proposal-source-phase-imports)
108
+
- `DecimalLiteral` - The [Decimal proposal](https://github.com/tc39/proposal-decimal) decided not to introduce new syntax. The `decimal` plugin will be removed from Babel 8.
109
+
- `importReflection` - The "Import Reflection" proposal has been renamed to ["Source Phase Imports"](https://github.com/tc39/proposal-source-phase-imports)
110
110
111
111
- [Disclaimer about non-standard syntax](https://prettier.io/docs/en/rationale.html#disclaimer-about-non-standard-syntax)
112
112
@@ -146,7 +146,7 @@ class Foo {
146
146
) {}
147
147
}
148
148
149
-
//Output (stable)
149
+
//Prettier 3.3
150
150
classFoo {
151
151
constructor(
152
152
@decorator
@@ -155,7 +155,7 @@ class Foo {
155
155
) {}
156
156
}
157
157
158
-
//Output (main)
158
+
//Prettier 3.4
159
159
classFoo {
160
160
constructor(
161
161
@decorator
@@ -172,7 +172,7 @@ There was a bug where block comments between the modifier and the name of a deco
172
172
With this change, the position of the block comment between the modifier and the property name is preserved.
173
173
174
174
<!-- prettier-ignore -->
175
-
```tsx
175
+
```ts
176
176
// Input
177
177
classFoo {
178
178
@decorator
@@ -204,7 +204,7 @@ There was a bug where an extra line was inserted when assigning a chained arrow
204
204
This change ensures that the extra line is no longer inserted.
205
205
206
206
<!-- prettier-ignore -->
207
-
```tsx
207
+
```ts
208
208
// Input
209
209
constfoo1=
210
210
// comment
@@ -229,7 +229,7 @@ const foo1 =
229
229
#### Support "Top-level await statements" ([#16729](https://github.com/prettier/prettier/pull/16729) by [@fisker](https://github.com/fisker))
#### Fix class heritage breaks even though it remains inside the line width ([#16730](https://github.com/prettier/prettier/pull/16730) by [@fisker](https://github.com/fisker))
@@ -282,7 +282,7 @@ export class JiraCreatePixFraudDetectionGateway
282
282
#### Print `declare` before accessibility in class properties ([#16731](https://github.com/prettier/prettier/pull/16731) by [@fisker](https://github.com/fisker))
283
283
284
284
<!-- prettier-ignore -->
285
-
```tsx
285
+
```ts
286
286
// Input
287
287
classA {
288
288
declare private readonly name: string;
@@ -415,7 +415,7 @@ Error
415
415
#### Fix wrong trailing comma position after comment in SCSS ([#16617](https://github.com/prettier/prettier/pull/16617) by [@Ma-hawaj](https://github.com/Ma-hawaj), [@fisker](https://github.com/fisker))
416
416
417
417
<!-- prettier-ignore -->
418
-
```css
418
+
```scss
419
419
/* Input */
420
420
$z-indexes: (
421
421
header:1035,
@@ -441,7 +441,7 @@ $z-indexes: (
441
441
442
442
In Prettier v3, [we print HTML5 doctype in lowercase](https://prettier.io/blog/2023/07/05/3.0.0#print-html5-doctype-in-lowercase-7391httpsgithubcomprettierprettierpull7391-by-fiskerhttpsgithubcomfisker), it's safe for HTML files, however users may use the `html` parser to format other files eg: XHTML files, lowercase the `doctype` will break XHTML documents.
443
443
444
-
Since Prettier 3.4, we'll only lowercase [HTML5 doctype (`<!doctype html>`)](https://developer.mozilla.org/en-US/docs/MDN/Writing_guidelines/Writing_style_guide/Code_style_guide/HTML#doctype) when the file extension is `.html` or `.htm`, otherwise they will be untouched.
444
+
Starting with Prettier 3.4, we'll only lowercase [HTML5 doctype (`<!doctype html>`)](https://developer.mozilla.org/en-US/docs/MDN/Writing_guidelines/Writing_style_guide/Code_style_guide/HTML#doctype) when the file extension is `.html` or `.htm`, otherwise they will be untouched.
0 commit comments