You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When building an app, I successfully setup the tailwind standalong package, but it seems like some of the tailwind css classes are missing in the output.css such as: "text-4xl", "animate-spin", "animate-bounce". I don't have an exhaustive list, but those are just a few.
the main.py is defined below. When running it, toggle the "hdrs=" line and you'll see the difference — using the CDN produces the correct screen, and using the standalone package does not. (screenshots below)
I expect that the CDN and the Standalone Package setup methods have identical output.css, assuming I execute the steps above and no others.
fromfasthtml.commonimport*fromshad4fastimport*app, rt=fast_app(
pico=False,
# hdrs=(ShadHead(tw_cdn=True, theme_handle=True),), # this one has all classeshdrs=(ShadHead(tw_cdn=False, theme_handle=True),), #this one does not
)
@rt("/")defget():
returnDiv(
Div(
Div(
H1(
"Here is a title",
cls="text-4xl tracking-tighter font-semibold mt-10 text-center animate-pulse",
),
P("Here is a paragraph",
cls="text-muted-foreground"
),
cls="space-y-3"
),
cls="w-full space-y-6 text-center"
),
cls="flex items-center min-h-screen px-4 py-12 sm:px-6 md:px-8 lg:px-12 xl:px-16"
)
serve()
When using the Standalone Package:
When using the CDN:
Am I setting tailwind up incorrectly or something? I made no edits to any of the tailwind files. I just ran the commands above in that order and got these results.
Thank you! The package is awesome by the way!
The text was updated successfully, but these errors were encountered:
Okay I fixed it. I just added all the following plugins to the described in the docs
This is probably the expected behavior given that it's outlined in the docs. Maybe that's correct given my limited understanding of tailwind, but I had the intuition that I could build my app using the CDN, then just run the scripts and change the tw_cd to false in the headers, and I'd be on my way.
When building an app, I successfully setup the tailwind standalong package, but it seems like some of the tailwind css classes are missing in the output.css such as: "text-4xl", "animate-spin", "animate-bounce". I don't have an exhaustive list, but those are just a few.
Steps to reproduce.
installations and setup:
pip install python-fasthtml
pip install shad4fast
shad4fast setup
shad4fast build
python main.py
the main.py is defined below. When running it, toggle the "hdrs=" line and you'll see the difference — using the CDN produces the correct screen, and using the standalone package does not. (screenshots below)
I expect that the CDN and the Standalone Package setup methods have identical output.css, assuming I execute the steps above and no others.
When using the Standalone Package:
When using the CDN:
Am I setting tailwind up incorrectly or something? I made no edits to any of the tailwind files. I just ran the commands above in that order and got these results.
Thank you! The package is awesome by the way!
The text was updated successfully, but these errors were encountered: