Preflight not for the whole site #16755
-
I am integrating an externally loaded embedded widget and would like to use Tailwind for styling. Is it possible to apply Tailwind's 3 Preflight reset exclusively to this widget without affecting the rest of the website? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
You could consider disabling the |
Beta Was this translation helpful? Give feedback.
-
I assigned the ID #widgetInside to the root element in shadow DOM, installed the Tailwind CSS Scoped Preflight plugin, and included it in the Tailwind plugins configuration. scopedPreflightStyles({
isolationStrategy: isolateInsideOfContainer(["#widgetInside"])
}), |
Beta Was this translation helpful? Give feedback.
I assigned the ID #widgetInside to the root element in shadow DOM, installed the Tailwind CSS Scoped Preflight plugin, and included it in the Tailwind plugins configuration.