From c89a48848d6daf8aed1c0f0f865130a8b3f3c96a Mon Sep 17 00:00:00 2001 From: Kevin Ghadyani Date: Thu, 4 Aug 2022 15:17:30 -0500 Subject: [PATCH] feat: added nonce capabilities for Okta apps --- packages/odyssey-react-theme/src/withTheme/stylesheet.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/odyssey-react-theme/src/withTheme/stylesheet.ts b/packages/odyssey-react-theme/src/withTheme/stylesheet.ts index ef86a2fc8a..f962d4f48b 100644 --- a/packages/odyssey-react-theme/src/withTheme/stylesheet.ts +++ b/packages/odyssey-react-theme/src/withTheme/stylesheet.ts @@ -17,6 +17,8 @@ export class OStyleSheet extends Set { super(); const el = document.createElement("style"); el.setAttribute("data-ods", ""); + // @ts-expect-error ts(2339) + el.setAttribute("nonce", window.nonce); this.element = document.head.appendChild(el); }