Skip to content

Commit

Permalink
fix: wrapper element when using runtimeCompiler
Browse files Browse the repository at this point in the history
  • Loading branch information
Sandros94 committed Mar 5, 2024
1 parent b577357 commit 75d3455
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/runtime/composables/use-nuxt-markdown.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,12 @@ export const useNuxtMarkdown = (source: MaybeRefOrGetter<string>, config?: DeepM
if (toValue(configDef.forceHtml) || !vueRuntimeCompiler) {
return h(configDef.as, { innerHTML: content.value, })
} else {
return h({
components: toValue(configDef.components),
render: compile(content.value),
})
return h(configDef.as, [
h({
components: toValue(configDef.components),
render: compile(content.value),
})
])
}
}

Expand Down

0 comments on commit 75d3455

Please sign in to comment.