Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite876132

Browse files
committed
Fix escaping of examples in JSDoc
1 parent14376c3 commite876132

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

‎packages/site-kit/src/lib/markdown/renderer.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -775,6 +775,14 @@ async function syntax_highlight({
775775

776776
html=html.replace(/{27,}/g,()=>redactions.shift()!);
777777

778+
/**
779+
*@shikijs/twoslash (as of v3.2.1) returns `<` in code blocks
780+
* inside of type tooltip-popups as `&#x3C;`.
781+
*
782+
* See {@link https://github.com/sveltejs/svelte.dev/issues/1283}.
783+
*/
784+
html=html.replaceAll('&#x3C;','<');
785+
778786
if(check){
779787
// munge the twoslash output so that it renders sensibly. the order of operations
780788
// here is important — we need to work backwards, to avoid corrupting the offsets

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp