From 400f007ad666beebf710acf607b6b44c07056c7a Mon Sep 17 00:00:00 2001 From: Eric Bailey Date: Tue, 5 Mar 2024 14:42:05 -0600 Subject: [PATCH] Ignore known type --- src/components/Menu/index.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/Menu/index.tsx b/src/components/Menu/index.tsx index f46185592f..ab8266070f 100644 --- a/src/components/Menu/index.tsx +++ b/src/components/Menu/index.tsx @@ -167,7 +167,8 @@ export function Group({children, style}: GroupProps) { ]}> {flattenReactChildren(children).map((child, i) => { // ignore null children, like Dividers - return React.isValidElement(child) && child.props.children ? ( + // @ts-ignore + return React.isValidElement(child) && child.props?.children ? ( {i > 0 ? (