Fix escaping of raw values that contain & in md preview

Fixes #236660
This commit is contained in:
Matt Bierner
2024-12-20 10:52:07 -08:00
parent e5f9272019
commit 7cf9dbecf6

View File

@@ -5,7 +5,10 @@
import * as vscode from 'vscode';
export function escapeAttribute(value: string | vscode.Uri): string {
return value.toString().replace(/"/g, '"');
return value.toString()
.replace(/&/g, '&')
.replace(/"/g, '"')
.replace(/'/g, ''');
}
export function getNonce() {