CHANGE: remove withDefaults
Remove with defaults as it is no longer needed
This commit is contained in:
parent
41a582fea4
commit
c82262e02d
2 changed files with 8 additions and 7 deletions
|
@ -12,9 +12,9 @@ type Props = {
|
||||||
label : string
|
label : string
|
||||||
}
|
}
|
||||||
|
|
||||||
const props = withDefaults(defineProps<Props>(), {
|
const {
|
||||||
type : 'a'
|
type = 'a'
|
||||||
})
|
} = defineProps<Props>()
|
||||||
|
|
||||||
const actualProps = () => {
|
const actualProps = () => {
|
||||||
if (props.type === 'a') {
|
if (props.type === 'a') {
|
||||||
|
|
|
@ -17,10 +17,11 @@ type Props = {
|
||||||
size?: 's' | 'm' | 'l'
|
size?: 's' | 'm' | 'l'
|
||||||
}
|
}
|
||||||
|
|
||||||
const {name, size, width} = withDefaults(defineProps<Props>(), {
|
const {
|
||||||
size: 'm',
|
name,
|
||||||
width: 50,
|
size = 'm',
|
||||||
})
|
width = 50,
|
||||||
|
} = defineProps<Props>()
|
||||||
|
|
||||||
const sizes = {
|
const sizes = {
|
||||||
s: 15,
|
s: 15,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue