Skip to content

Commit

Permalink
#39694 Fix "two children with the same key" warning when using <App /> (
Browse files Browse the repository at this point in the history
  • Loading branch information
Kamahl19 committed Dec 21, 2022
1 parent d43b8e7 commit d93bca1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion components/message/useMessage.tsx
Expand Up @@ -212,7 +212,7 @@ export function useInternalMessage(
}, []);

// ============================== Return ===============================
return [wrapAPI, <Holder key="holder" {...notificationConfig} ref={holderRef} />];
return [wrapAPI, <Holder key="message-holder" {...notificationConfig} ref={holderRef} />];
}

export default function useMessage(notificationConfig?: ConfigOptions) {
Expand Down
2 changes: 1 addition & 1 deletion components/notification/useNotification.tsx
Expand Up @@ -160,7 +160,7 @@ export function useInternalNotification(
}, []);

// ============================== Return ===============================
return [wrapAPI, <Holder key="holder" {...notificationConfig} ref={holderRef} />];
return [wrapAPI, <Holder key="notification-holder" {...notificationConfig} ref={holderRef} />];
}

export default function useNotification(notificationConfig?: NotificationConfig) {
Expand Down

0 comments on commit d93bca1

Please sign in to comment.