Skip to content

Commit

Permalink
use "?url" suffix in "tailwind.css" import (Remix) (#4945)
Browse files Browse the repository at this point in the history
Importing `tailwind.css` is incorrect as it will treat that file as a CSS Module, throwing that it has no `default` export. 

Instead, the tutorial relies on the import returning a _URL_ to the stylesheet. Adding `?url` to the import specifier is the way to go.
  • Loading branch information
kettanaito authored Sep 26, 2024
1 parent 28f34ed commit 7dfdb02
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/www/content/docs/installation/remix.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ export default {
In your `app/root.tsx` file, import the `tailwind.css` file:

```js {1, 4}
import styles from "./tailwind.css"
import styles from "./tailwind.css?url"

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

0 comments on commit 7dfdb02

Please sign in to comment.