From b6d9e54d02df3f7bad47fbd8c880bc1a2e9e2aae Mon Sep 17 00:00:00 2001 From: Farnabaz Date: Wed, 10 Nov 2021 16:01:44 +0330 Subject: [PATCH] fix(Markdown): handle text nodes --- src/runtime/components/Markdown.vue | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/runtime/components/Markdown.vue b/src/runtime/components/Markdown.vue index c53c32e44..74b03a331 100644 --- a/src/runtime/components/Markdown.vue +++ b/src/runtime/components/Markdown.vue @@ -72,7 +72,9 @@ export default { console.warn('Markdown: This is likely to happen when you use `unwrap` attribute.') } else { const tmpNode = Array.isArray(node) ? node[0] : node - Object.assign(tmpNode.data, ctx.data) + if (tmpNode?.data) { + Object.assign(tmpNode.data, ctx.data) + } } return node