Skip to content

Commit

Permalink
fix(Markdown): handle text nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
farnabaz committed Nov 10, 2021
1 parent 4f59e12 commit b6d9e54
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/runtime/components/Markdown.vue
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down

0 comments on commit b6d9e54

Please sign in to comment.