/posts
Code Blocks Demo
Examples of the enhanced code blocks with language labels and copy buttons.
Below are a few examples showing the enhanced code blocks.
// Basic JavaScript example
export function greet(name) {
return `Hello, ${name}!`;
}
console.log(greet('Orbit'));
# Bash example with a few lines
set -euo pipefail
echo "Building..."
hugo --minify
# Snippet from config.toml
[markup.highlight]
style = "dracula"
noClasses = false
// No language set (renders as plain text)
some text-only code fence