mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 20:26:08 +00:00
Allow Markdown-Rendering Without Providing an Env-Parameter (#117041)
* Add a rule for initializing the image-stabilizer * Only use `containingImages` if the variable exists
This commit is contained in:
@@ -216,7 +216,7 @@ export class MarkdownEngine {
|
|||||||
|
|
||||||
const src = token.attrGet('src');
|
const src = token.attrGet('src');
|
||||||
if (src) {
|
if (src) {
|
||||||
env.containingImages.push({ src });
|
env.containingImages?.push({ src });
|
||||||
const imgHash = hash(src);
|
const imgHash = hash(src);
|
||||||
token.attrSet('id', `image-hash-${imgHash}`);
|
token.attrSet('id', `image-hash-${imgHash}`);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user