#fonts not loading

1 messages · Page 1 of 1 (latest)

frozen tusk
#

so im loading inter font via next/font/google and though i have a strong internet connection it is throwing 404, i tried visiting the google fonts api manually in my browser and it did respond with the css code, but the next app is unable to load font

// layout.tsx

import "~/styles/globals.css";

import { type Metadata } from "next";
import { Inter } from "next/font/google";

export const metadata: Metadata = {
  title: "Create T3 App",
  description: "Generated by create-t3-app",
  icons: [{ rel: "icon", url: "/favicon.ico" }],
};

const inter = Inter({
  subsets: ["latin"],
  display: "swap",
  variable: "--font-inter",
});

export default function RootLayout({
  children,
}: Readonly<{ children: React.ReactNode }>) {
  return (
    <html lang="en" className={`${inter.variable}`}>
      <body>{children}</body>
    </html>
  );
}
sharp remnantBOT
#

🔎 This post has been indexed in our web forum and will be seen by search engines so other users can find it outside Discord

🕵️ Your user profile is private by default and won't be visible to users outside Discord, if you want to be visible in the web forum you can add the "Public Profile" role in id:customize

✅ You can mark a message as the answer for your post with Right click -> Apps -> Mark Solution
(if you don't see the option, try refreshing Discord with Ctrl + R)

frozen tusk
#

this doesnt happen in prod btw

boreal blade
#

so thats not just me having that issue?

frozen tusk
#

probably

frozen tusk
#

like when you build and run

#

or on vercel

boreal blade
#

it only happens in dev

#

a lot

#

prod seems to work fine