From 84df755c892dfe6ab49825c5e4004481285815d4 Mon Sep 17 00:00:00 2001 From: russell <879917302@qq.com> Date: Mon, 6 May 2024 18:36:22 +0800 Subject: [PATCH] fix(option): prop.label or prop.value is undefined --- packages/fighting-design/option/src/option.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/fighting-design/option/src/option.vue b/packages/fighting-design/option/src/option.vue index 090bc214f5..783247ee95 100644 --- a/packages/fighting-design/option/src/option.vue +++ b/packages/fighting-design/option/src/option.vue @@ -45,7 +45,7 @@ } /** 获取到 label */ - const label = slotLabel.value || prop.label.toString() || prop.value.toString() + const label = slotLabel.value || prop.label?.toString() || prop.value?.toString() /** 获取到选中的项目 */ const currentItem = parentInject.childrenLabels.find(item => { return item.slot === label