The w3-code class formats a code block with a monospace font, padding, and a colored left border.
Use a pre element to preserve line breaks and indentation.
<h2>Hello World</h2> <p>This is a paragraph.</p>
h1 { color: teal; }
const x = 5; const y = 2; const total = x + y;
Syntax highlighting requires a separate script. It is not provided by the w3-code class.