I'm struggling with implementing a widget based on create react app, particularly, I'm unable to add my global styles to the shadow root since style-loader injects them into head
Could you please give some direction how to fix this? Maybe it is possible to attach to an pre-existing shadowRoot?
I've tried
import style from "./css/site.css";
<style type="text/css">{style.toString()}</style>
but this gives me
<style type="text/css">[object Module]</style>
use inline loader to import pure string styles from css
import tailwindCSS from "@/styles/tailwind.less?inline";
and then
<style type="text/css">{tailwindCSS}</style>
I'm struggling with implementing a widget based on create react app, particularly, I'm unable to add my global styles to the shadow root since
style-loader
injects them intohead
Could you please give some direction how to fix this? Maybe it is possible to attach to an pre-existingshadowRoot
?I've tried
but this gives me
<style type="text/css">[object Module]</style>