Skip to content

Instantly share code, notes, and snippets.

@rahulmore01
Last active January 4, 2024 02:22
Show Gist options
  • Save rahulmore01/e49aa02eda144a49b4c287d2466e8d8a to your computer and use it in GitHub Desktop.
Save rahulmore01/e49aa02eda144a49b4c287d2466e8d8a to your computer and use it in GitHub Desktop.
react-hot-toast
import "./globals.css";
import { Inter } from "next/font/google";
import { Toaster } from "react-hot-toast";
const inter = Inter({ subsets: ["latin"] });
export const metadata = {
title: "Create Next App",
description: "Generated by create next app",
};
export default function RootLayout({ children }) {
return (
<html lang="en">
<body className={inter.className}>
// make sure to keep toaster above children
<Toaster position="bottom-center" />
{children}
</body>
</html>
);
}
@TheLegendaryJedi
Copy link

Hi! Thanks a lot for your starter. You just need to remove the space after "bottom-center" for it to compile in TS.

@rahulmore01
Copy link
Author

@TheLegendaryJedi i have updated it, @rahulmoreweb3 my Twitter, let's connect.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment