diff --git a/.github/ISSUE_TEMPLATE/formatting.md b/.github/ISSUE_TEMPLATE/formatting.md index a5330db4c..741e9cf03 100644 --- a/.github/ISSUE_TEMPLATE/formatting.md +++ b/.github/ISSUE_TEMPLATE/formatting.md @@ -26,7 +26,7 @@ Don't fill the form below manually! Let a program create a report for you: --> -**Prettier 3.3.0** +**Prettier 3.3.1** [Playground link](https://prettier.io/playground/#.....) ```sh diff --git a/.github/ISSUE_TEMPLATE/integration.md b/.github/ISSUE_TEMPLATE/integration.md index e1e0e1bb7..a64d9bf9c 100644 --- a/.github/ISSUE_TEMPLATE/integration.md +++ b/.github/ISSUE_TEMPLATE/integration.md @@ -20,7 +20,7 @@ BEFORE SUBMITTING AN ISSUE: **Environments:** -- Prettier Version: 3.3.0 +- Prettier Version: 3.3.1 - Running Prettier via: - Runtime: - Operating System: diff --git a/CHANGELOG.md b/CHANGELOG.md index 3f419f156..609324a3c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,85 @@ +# 3.3.1 + +[diff](https://github.com/prettier/prettier/compare/3.3.0...3.3.1) + +#### Preserve empty lines in front matter ([#16347](https://github.com/prettier/prettier/pull/16347) by [@fisker](https://github.com/fisker)) + + +```markdown + +--- +foo: + - bar1 + + - bar2 + + - bar3 +--- +Markdown + + + +--- +foo: + - bar1 + - bar2 + - bar3 +--- + +Markdown + + + +--- +foo: + - bar1 + + - bar2 + + - bar3 +--- + +Markdown +``` + +#### Preserve explicit language in front matter ([#16348](https://github.com/prettier/prettier/pull/16348) by [@fisker](https://github.com/fisker)) + + +```markdown + +---yaml +title: Hello +slug: home +--- + + +--- +title: Hello +slug: home +--- + + +---yaml +title: Hello +slug: home +--- +``` + +#### Avoid line breaks in import attributes ([#16349](https://github.com/prettier/prettier/pull/16349) by [@fisker](https://github.com/fisker)) + + +```jsx +// Input +import something from "./some-very-very-very-very-very-very-very-very-long-path.json" with { type: "json" }; + +// Prettier 3.3.0 +import something from "./some-very-very-very-very-very-very-very-very-long-path.json" with { type: + "json" }; + +// Prettier 3.3.1 +import something from "./some-very-very-very-very-very-very-very-very-long-path.json" with { type: "json" }; +``` + # 3.3.0 [diff](https://github.com/prettier/prettier/compare/3.2.5...3.3.0) diff --git a/docs/browser.md b/docs/browser.md index 1b9651944..38e78d5e5 100644 --- a/docs/browser.md +++ b/docs/browser.md @@ -18,7 +18,7 @@ Required options: - **[`parser`](options.md#parser) (or [`filepath`](options.md#file-path))**: One of these options has to be specified for Prettier to know which parser to use. -- **`plugins`**: Unlike the `format` function from the [Node.js-based API](api.md#prettierformatsource--options), this function doesn’t load plugins automatically. The `plugins` option is required because all the parsers included in the Prettier package come as plugins (for reasons of file size). These plugins are files in . Note that `estree` plugin should be loaded when printing JavaScript, TypeScript, Flow, or JSON. +- **`plugins`**: Unlike the `format` function from the [Node.js-based API](api.md#prettierformatsource--options), this function doesn’t load plugins automatically. The `plugins` option is required because all the parsers included in the Prettier package come as plugins (for reasons of file size). These plugins are files in . Note that `estree` plugin should be loaded when printing JavaScript, TypeScript, Flow, or JSON. You need to load the ones that you’re going to use and pass them to `prettier.format` using the `plugins` option. @@ -29,8 +29,8 @@ See below for examples. ### Global ```html - - + + - + +