Skip to content

Instantly share code, notes, and snippets.

@MoOx
Last active May 29, 2025 15:36
Show Gist options
  • Save MoOx/5271067 to your computer and use it in GitHub Desktop.
Save MoOx/5271067 to your computer and use it in GitHub Desktop.
How to make comment in JSON file
{
"//field": "These 'double quote' 'double quote' are used as comments, because JSON doesnt' allow comment",
"field": {},
"#another-field": "Another comment",
"another-field": {},
"/*stuff": "Be careful to use them when you have full control of the content :)",
"stuff": [],
"bla": "bla"
}
@safepestsol
Copy link

You can add a dedicated key to your JSON Safe Pest Sol object for storing comments—JSON parsers that don’t recognize it will simply ignore it, allowing you to include notes without affecting functionality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment