Skip to content

Instantly share code, notes, and snippets.

@DamianEdwards
Last active May 8, 2025 21:06
Show Gist options
  • Save DamianEdwards/31d2457737304ca73556 to your computer and use it in GitHub Desktop.
Save DamianEdwards/31d2457737304ca73556 to your computer and use it in GitHub Desktop.
JSON comments on GH

What happens if you tell GitHub it's JSON

{
  "hello": "world" // I want my comments!
}

Use jsonc as the language instead

{
  "hello": "world" // I want my comments!
}

Or just tell GitHub it's JavaScript

{
  "hello": "world" // I want my comments!
}
{
"hello": "world" // I want my comments!
}
@atticus-arctiq
Copy link

What happens if you tell GitHub it's JSON

{
  "hello": "world" // I want my comments!
}

Use jsonc as the language instead

{
  "hello": "world" // I want my comments!
}

Or just tell GitHub it's JavaScript

{
  "hello": "world" // I want my comments!
}

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