소스 검색

Cascader: correct type definitions of CascaderOption (#13613)

Allows `children` and `disabled` to be undefined
NateScarlet 6 년 전
부모
커밋
62cce0e98c
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      types/cascader.d.ts

+ 2 - 2
types/cascader.d.ts

@@ -7,8 +7,8 @@ export type ExpandTrigger = 'click' | 'hover'
 export interface CascaderOption {
   label: string,
   value: any,
-  children: CascaderOption[],
-  disabled: boolean
+  children?: CascaderOption[],
+  disabled?: boolean
 }
 
 /** Cascader Component */