Skip to main content
edited tags
Link
Rob
  • 19.2k
  • 7
  • 44
  • 96
grammar
Source Link
user313042
user313042

In a nutshell: If you want to declare the language for syntax highlighting in your code block, use the code-fence notation and not indented code blocks. You can still use indented code blocks, but declaredeclaring the preferred language explicitly for them is no longer supported moving forward.

In a nutshell: If you want to declare the language for syntax highlighting in your code block, use the code-fence notation and not indented code blocks. You can still use indented code blocks, but declare the preferred language explicitly for them is no longer supported moving forward.

In a nutshell: If you want to declare the language for syntax highlighting in your code block, use the code-fence notation and not indented code blocks. You can still use indented code blocks, but declaring the preferred language explicitly for them is no longer supported moving forward.

see /posts/comments/1167297
Source Link

In a nutshell: If you want to declare the language for syntax highlighting in your code block, use the code-fence notation and not indented code blocks. You can still use indented code blocks, but can’t declare the preferred language explicitly for them is no longer supported moving forward.

Until now, you could do this to declare the language for an indented code block.:

Moving forward, this won’t work anymorestyle is considered deprecated. Ever since we’ve introduced code fences, you can explicitly declare the language of a code block using the code fence notation:

This is the way the CommonMark standard is proposing and this is what other websites are doing, too. We know that you might have gotten used to using the old syntax featuring a <!-- language: lang --> comment. As we’re adopting new Markdown parsers, we want to avoid patching quirky behavior into those parsers when there’s an official, standards-compliant way of achieving the same goal that we can adopt with no extra effort. This style will continue to work for the time being, but is subject to removal in the future, at which point posts using it will no longer recognize it.

In a nutshell: If you want to declare the language for syntax highlighting in your code block, use the code-fence notation and not indented code blocks. You can still use indented code blocks but can’t declare the preferred language explicitly moving forward.

Until now, you could do this to declare the language for an indented code block.

Moving forward, this won’t work anymore. Ever since we’ve introduced code fences, you can explicitly declare the language of a code block using the code fence notation:

This is the way the CommonMark standard is proposing and this is what other websites are doing, too. We know that you might have gotten used to using the old syntax featuring a <!-- language: lang --> comment. As we’re adopting new Markdown parsers, we want to avoid patching quirky behavior into those parsers when there’s an official, standards-compliant way of achieving the same goal that we can adopt with no extra effort.

In a nutshell: If you want to declare the language for syntax highlighting in your code block, use the code-fence notation and not indented code blocks. You can still use indented code blocks, but declare the preferred language explicitly for them is no longer supported moving forward.

Until now, you could do this to declare the language for an indented code block:

Moving forward, this style is considered deprecated. Ever since we’ve introduced code fences, you can explicitly declare the language of a code block using the code fence notation:

This is the way the CommonMark standard is proposing and this is what other websites are doing, too. We know that you might have gotten used to using the old syntax featuring a <!-- language: lang --> comment. As we’re adopting new Markdown parsers, we want to avoid patching quirky behavior into those parsers when there’s an official, standards-compliant way of achieving the same goal that we can adopt with no extra effort. This style will continue to work for the time being, but is subject to removal in the future, at which point posts using it will no longer recognize it.

Notice removed Reward existing answer by Jeff Atwood
Bounty Ended with Ham Vocke's answer chosen by Jeff Atwood
edited tags
Link
Yaakov Ellis StaffMod
  • 64.3k
  • 26
  • 286
  • 335
Loading
Notice added Reward existing answer by Jeff Atwood
Bounty Started worth 500 reputation by Jeff Atwood
Make current status more visible, 🍎
Source Link
Loading
edited tags
Link
Ham Vocke StaffMod
  • 12.3k
  • 7
  • 21
  • 26
Loading
🍎
Source Link
Loading
Add a link to quickly go through *screens* of text, 🍎
Source Link
Loading
added 8 characters in body
Source Link
Loading
minor grammar fix
Source Link
Loading
Formatting. If the philosophy is to separate formatting marks by spaces (which is good), we should also champion this for code fences.
Source Link
Wrzlprmft
  • 28.7k
  • 5
  • 78
  • 153
Loading
Included the code fence so the language selection can be visible since the paragraph is explaining that feature
Source Link
terdon
  • 26.6k
  • 7
  • 56
  • 91
Loading
fix quotes in code examples
Source Link
ThiefMaster
  • 15.7k
  • 6
  • 48
  • 87
Loading
edited tags
Link
JNat StaffMod
  • 27.9k
  • 18
  • 108
  • 146
Loading
Source Link
Ham Vocke StaffMod
  • 12.3k
  • 7
  • 21
  • 26
Loading