From dc18d415e52ab9f89e310e7df7dded938ae53013 Mon Sep 17 00:00:00 2001 From: Kevin Ghadyani Date: Wed, 23 Oct 2024 15:27:07 -0500 Subject: [PATCH] fix: adds deprecation message on createShadowDomElements --- packages/odyssey-react-mui/src/web-component/shadow-dom.ts | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/odyssey-react-mui/src/web-component/shadow-dom.ts b/packages/odyssey-react-mui/src/web-component/shadow-dom.ts index 796a7625e..b00b222eb 100644 --- a/packages/odyssey-react-mui/src/web-component/shadow-dom.ts +++ b/packages/odyssey-react-mui/src/web-component/shadow-dom.ts @@ -28,6 +28,9 @@ export type ShadowDomElements = ReturnType< typeof createUnattachedShadowDomElements >; +/** + * @deprecated Use `renderReactInWebComponent` instead. This function was necessary when using bare Shadow DOM, but with UI Shell rendering in a Web Component, you won't be able to render your Shadow DOM in its Shadow DOM without using a Web Component. + */ export const createShadowDomElements = (containerElement: HTMLElement) => { const shadowRoot = containerElement.attachShadow({ mode: "open" });