Skip to content
Discussion options

You must be logged in to vote

The issue is with the links export in root.tsx. If you don't have a CSS bundle, the ternary will always return [], so it doesn't include the tailwind styles. Remix is building the CSS file just fine. You can look in /public/build/_assets.

Change links from

export const links: LinksFunction = () => [
  ...(cssBundleHref
    ? [
        { rel: "stylesheet", href: cssBundleHref },
        { rel: "stylesheet", href: styles },
      ]
    : []),
];

to this

export const links: LinksFunction = () => [{ rel: "stylesheet", href: styles }];

Replies: 4 comments 5 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@MichaelDeBoey
Comment options

@mhanifmuhsin
Comment options

Answer selected by MichaelDeBoey
Comment options

You must be logged in to vote
2 replies
@kiliman
Comment options

@Mihai-github
Comment options

Comment options

You must be logged in to vote
1 reply
@kiliman
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants