From 154d76f221f1996e8201162c720487d813e5ead7 Mon Sep 17 00:00:00 2001
From: Eric Liu The default Highlight component requires two props:Installation
@@ -64,7 +64,7 @@
Usage
code
: text to highlight
Import styles from svelte-highlight/styles
.
Use the HighlightSvelte
component for Svelte syntax
highlighting.
The HighlightAuto
component invokes the
highlightAuto
API from highlight.js
.
Use the LineNumbers
component to render the highlighted
code with line numbers.
Set hideBorder
to true
to hide the border of the line numbers column.
By default, overflowing horizontal content is contained by a scrollbar.
@@ -193,43 +193,43 @@pre
element.
Use --style-props
to customize visual properties.
Use startingLineNumber
to customize the starting
line number. By default, line numbers start at
1
.
Use highlightedLines
to highlight specific lines.
Indices start at zero.
Use --highlighted-background
to customize the background
color of highlighted lines.
All Highlight
components apply a
data-language
attribute on the codeblock containing
@@ -250,7 +250,7 @@
of supported languages.
All Highlight
components allow for a tag to be added
at the top-right of the codeblock displaying the language name. Customize the
@@ -285,7 +285,7 @@
of supported languages.
Get started with
Date: Sun, 2 Feb 2025 11:03:32 -0800
Subject: [PATCH 2/2] docs: leverage `content-visibility: auto` for large lists
---
www/components/globals/Languages.svelte | 1 +
www/components/globals/Styles.svelte | 1 +
2 files changed, 2 insertions(+)
diff --git a/www/components/globals/Languages.svelte b/www/components/globals/Languages.svelte
index 17cbf16..c9e512b 100644
--- a/www/components/globals/Languages.svelte
+++ b/www/components/globals/Languages.svelte
@@ -43,6 +43,7 @@
{#each languages as language (language.name)}