Code Highlighter
- CodeHighlighter is a component that provides syntax highlighting for code snippets.
- It supports various programming languages and can display line numbers for better readability.
Usage
const helloWorld = () => alert ('Hello World!');
export { helloWorld };
In line code
const helloWorld = () => alert ('Hello World!');
<wc-code-highlighter line-numbers="true" language="javascript">
<pre><code>
const helloWorld = () => alert ('Hello World!');
export { helloWorld };
</code></pre>
</code-highlighter>
</DemoComponentCard>
<DemoComponentCard lang='html'>
<h3 class='text-headline'>In line code
<code class='text-code-block'>const helloWorld = () => alert ('Hello World!');</code>
</h3>
</DemoComponentCard></wc-code-highlighter>
On this page