From 8fe372b02bb77c32151875ce6ee311fa3be70fbf Mon Sep 17 00:00:00 2001
From: Luke Latham <1622880+guardrex@users.noreply.github.com>
Date: Thu, 27 Feb 2025 07:51:35 -0500
Subject: [PATCH 1/3] Silencing JSON comment errors
---
aspnetcore/fundamentals/configuration/index.md | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/aspnetcore/fundamentals/configuration/index.md b/aspnetcore/fundamentals/configuration/index.md
index 7427800d5427..4975dba8a8b0 100644
--- a/aspnetcore/fundamentals/configuration/index.md
+++ b/aspnetcore/fundamentals/configuration/index.md
@@ -138,6 +138,16 @@ Using the [default](#default) configuration, the `appsettings.json` and `appsett
Comments in `appsettings.json` and `appsettings.{Environment}.json` files are supported using JavaScript or [C# style comments](/dotnet/csharp/language-reference/tokens/comments).
+Some integrated development environments (IDE) display an error when editing a JSON file that contains comments. Often, the error can be disabled with a setting in the IDE. In Visual Studio Code, for example, add the following to the `settings.json` file to disable the error:
+
+```json
+"files.associations": {
+ "appsettings*.json": "jsonc"
+}
+```
+
+For other IDEs, check the tool's documentation and other product support channels to determine how to silence the error.
+
### Bind hierarchical configuration data using the options pattern
From 32b028809aadc0f1ee593432f36f9bc0b9332aa2 Mon Sep 17 00:00:00 2001
From: Luke Latham <1622880+guardrex@users.noreply.github.com>
Date: Thu, 27 Feb 2025 09:41:30 -0500
Subject: [PATCH 2/3] Updates
---
aspnetcore/fundamentals/configuration/index.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/aspnetcore/fundamentals/configuration/index.md b/aspnetcore/fundamentals/configuration/index.md
index 4975dba8a8b0..25953e68fbb9 100644
--- a/aspnetcore/fundamentals/configuration/index.md
+++ b/aspnetcore/fundamentals/configuration/index.md
@@ -138,7 +138,7 @@ Using the [default](#default) configuration, the `appsettings.json` and `appsett
Comments in `appsettings.json` and `appsettings.{Environment}.json` files are supported using JavaScript or [C# style comments](/dotnet/csharp/language-reference/tokens/comments).
-Some integrated development environments (IDE) display an error when editing a JSON file that contains comments. Often, the error can be disabled with a setting in the IDE. In Visual Studio Code, for example, add the following to the `settings.json` file to disable the error:
+Some integrated development environments (IDE) display errors when editing a JSON file that contains comments. Often, the errors can be disabled with a setting in the IDE. In Visual Studio Code, for example, add the following to the `settings.json` file to disable the errors:
```json
"files.associations": {
@@ -146,7 +146,7 @@ Some integrated development environments (IDE) display an error when editing a J
}
```
-For other IDEs, check the tool's documentation and other product support channels to determine how to silence the error.
+For other IDEs, check the tool's documentation and other product support channels to determine how to silence the errors.
From 69b199c6aae03df534bee3656c8a2895e69e33e4 Mon Sep 17 00:00:00 2001
From: Luke Latham <1622880+guardrex@users.noreply.github.com>
Date: Thu, 27 Feb 2025 15:18:03 -0500
Subject: [PATCH 3/3] Updates
---
aspnetcore/fundamentals/configuration/index.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/aspnetcore/fundamentals/configuration/index.md b/aspnetcore/fundamentals/configuration/index.md
index 25953e68fbb9..62fe29e96066 100644
--- a/aspnetcore/fundamentals/configuration/index.md
+++ b/aspnetcore/fundamentals/configuration/index.md
@@ -138,7 +138,7 @@ Using the [default](#default) configuration, the `appsettings.json` and `appsett
Comments in `appsettings.json` and `appsettings.{Environment}.json` files are supported using JavaScript or [C# style comments](/dotnet/csharp/language-reference/tokens/comments).
-Some integrated development environments (IDE) display errors when editing a JSON file that contains comments. Often, the errors can be disabled with a setting in the IDE. In Visual Studio Code, for example, add the following to the `settings.json` file to disable the errors:
+Some integrated development environments (IDE) display errors when editing a JSON file that contains comments. You can generally ignore comment errors and warnings, but you can also usually disable them with a setting in the IDE. In Visual Studio Code, for example, add the following to the `settings.json` file to disable the errors:
```json
"files.associations": {