mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2025-01-30 12:52:43 +08:00
fix(md-loader): code is compiled to dynamic content
This commit is contained in:
parent
d1d4e69b51
commit
33b67676cb
@ -41,7 +41,7 @@ function createRenderer (wrapCodeWithCard = true) {
|
||||
)
|
||||
}
|
||||
const highlighted = hljs.highlight(language, code).value
|
||||
const content = `<n-code><pre>${highlighted}</pre></n-code>`
|
||||
const content = `<n-code><pre v-pre>${highlighted}</pre></n-code>`
|
||||
return wrapCodeWithCard
|
||||
? `<n-card size="small" class="md-card">${content}</n-card>`
|
||||
: content
|
||||
|
@ -31,7 +31,6 @@ function mapSlot (
|
||||
for (let i = 0; i < defaultSlot.length; ++i) {
|
||||
const wrappedInstance = defaultSlot[i]
|
||||
const name = (wrappedInstance.type as any)?.name
|
||||
console.log(name)
|
||||
if (name === 'RadioButton') {
|
||||
isButtonGroup = true
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user