Skip to content

Commit

Permalink
fix!: improve tailwind handling
Browse files Browse the repository at this point in the history
  • Loading branch information
dy0gu committed Sep 14, 2024
1 parent 65ede44 commit 442cafe
Show file tree
Hide file tree
Showing 12 changed files with 25 additions and 34 deletions.
2 changes: 1 addition & 1 deletion biome.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
}
},
{
"include": ["src/app/routes/*.tsx"],
"include": ["src/routes/*.tsx"],
"linter": {
"rules": {
"style": {
Expand Down
24 changes: 12 additions & 12 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,15 +31,15 @@
"zod": "^3.23.8"
},
"devDependencies": {
"@playwright/test": "^1.47.1",
"@biomejs/biome": "~1.9.0",
"@playwright/test": "^1.47.1",
"@types/node": "^22.5.4",
"@types/react": "^18.3.5",
"@types/react-dom": "^18.3.0",
"autoprefixer": "^10.4.20",
"cross-env": "^7.0.3",
"lefthook": "^1.7.15",
"postcss": "^8.4.45",
"postcss": "^8.4.47",
"tailwindcss": "^3.4.11",
"typescript": "^5.6.2",
"vite": "^5.4.5",
Expand Down
3 changes: 3 additions & 0 deletions src/data/attributes.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import stylesheet from "~/styles/tailwind.css?url";

// Reusable values throughout the app
const info = {
name: "Dy0gu",
Expand All @@ -16,6 +18,7 @@ const rels = [
{ rel: "icon", href: "/favicon.svg", type: "image/svg+xml" },
{ rel: "sitemap", href: "/sitemap.xml" },
{ rel: "manifest", href: "/manifest.webmanifest" },
{ rel: "stylesheet", href: stylesheet },
];

export { info, rels };
11 changes: 5 additions & 6 deletions src/app/root.tsx → src/root.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,8 @@ import {
Scripts,
ScrollRestoration,
} from "@remix-run/react";

import { metadata } from "~/data/meta";

import { rels } from "~/data/attributes";

import "~/styles/globals.css";
import { metadata } from "~/data/meta";

export function loader() {
return json(metadata);
Expand All @@ -37,7 +33,10 @@ export default function Layout() {
<Meta />
<Links />
</head>
<body className="bg-black bg-gradient-to-tl from-black via-zinc-600/20 to-black">
<body
className="bg-black bg-gradient-to-tl from-black via-zinc-600/20 to-black
font-mono"
>
<Outlet />
<ScrollRestoration />
<Scripts />
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
12 changes: 0 additions & 12 deletions src/styles/globals.css → src/styles/tailwind.css
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,4 @@
font-style: italic;
src: url("../assets/fonts/RobotoMono-Italic.ttf") format("truetype");
}

body {
font-family: "Roboto Mono", monospace;
overscroll-behavior-y: none;
margin: 0;
}

ul {
list-style-type: none;
padding: 0;
margin: 0;
}
}
1 change: 1 addition & 0 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"compilerOptions": {
"types": ["@remix-run/node", "vite/client"],
"paths": {
"~/*": ["./src/*"]
},
Expand Down
2 changes: 1 addition & 1 deletion vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import tsconfigPaths from "vite-tsconfig-paths";
export default defineConfig({
plugins: [
remix({
appDirectory: "src/app",
appDirectory: "src",
}),
tsconfigPaths(),
],
Expand Down

0 comments on commit 442cafe

Please sign in to comment.