-
|
Hello! I am wanting to create a PWA prefix(is this the right term even?) in Tailwind, where when I add pwa:bg-red-700 (for example), it applies it when viewing the app as a progressive web app. This would be very similar to Tailwind's dark mode (dark:some-style-700), which gets applied when the dark class is applied to the root element. https://tailwindcss.com/docs/dark-mode I have the logic for adding pwa class on the root, but am pretty fuzzy on what else would need to be done. I believe I need to add a variant function, then extend all of the styles I want to be affected by this variant. If anyone has any resources, examples or pointers for getting this done, I'd hugely appreciate it. Thank you in advance! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Figured it out. For anyone in need (React): app.tsx tailwind.config |
Beta Was this translation helpful? Give feedback.
Figured it out. For anyone in need (React):
app.tsx
tailwind.config