mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 12:14:41 +01:00
docs(ComponentCode): allow empty string in v-model
This commit is contained in:
@@ -101,7 +101,7 @@ const code = computed(() => {
|
||||
<template>
|
||||
<${name}`
|
||||
for (const [key, value] of Object.entries(componentProps)) {
|
||||
if (value === undefined || value === null || value === '' || props.hide?.includes(key)) {
|
||||
if (value === undefined || value === null || props.hide?.includes(key)) {
|
||||
continue
|
||||
}
|
||||
|
||||
@@ -110,6 +110,10 @@ const code = computed(() => {
|
||||
continue
|
||||
}
|
||||
|
||||
if (value === '') {
|
||||
continue
|
||||
}
|
||||
|
||||
const prop = meta?.meta?.props?.find((prop: any) => prop.name === key)
|
||||
const name = kebabCase(key)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user