From e8325318a0f96405c2d40b11be9e8be128058f62 Mon Sep 17 00:00:00 2001 From: Kunall Banerjee Date: Thu, 26 Feb 2026 12:07:25 -0500 Subject: [PATCH] languages: Add `.prettierrc` to JSON `path_suffixes` (#50156) `.prettierrc` can be [written](https://prettier.io/docs/configuration) in either JSON or YAML. Whether you write JSON or YAML, VS Code will default to recognizing it as JSON. See screenshot. Without this change, the user is forced to do: ```jsonc "file_types": { "JSON": [".prettierrc"], }, ``` Small QoL improvement. | VS Code | Zed (after the changes) | |--------|--------| | image | image | Closes #50072. Before you mark this PR as ready for review, make sure that you have: - [x] Added a solid test coverage and/or screenshots from doing manual testing - [x] Done a self-review taking into account security and performance aspects - [x] Aligned any UI changes with the [UI checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) Release Notes: - Added `.prettierrc` to JSON `path_suffixes` --- crates/languages/src/json/config.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/languages/src/json/config.toml b/crates/languages/src/json/config.toml index fa74f0d8f3eddcbe5086d3e14ab3eba19751235c..fcae481bebbdff01957c55190266af545f346327 100644 --- a/crates/languages/src/json/config.toml +++ b/crates/languages/src/json/config.toml @@ -1,6 +1,6 @@ name = "JSON" grammar = "json" -path_suffixes = ["json", "flake.lock", "geojson"] +path_suffixes = ["json", "flake.lock", "geojson", "prettierrc"] line_comments = ["// "] autoclose_before = ",]}" brackets = [