Skip to content

Commit 0ac2326

Browse files
Copilotsyed-reza98
andcommitted
Add @vercel/speed-insights and fix remaining toast implementation
Co-authored-by: syed-reza98 <71028588+syed-reza98@users.noreply.github.com>
1 parent 455d4ca commit 0ac2326

File tree

4 files changed

+40
-4
lines changed

4 files changed

+40
-4
lines changed

package-lock.json

Lines changed: 36 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
"@tanstack/react-table": "^8.21.3",
5353
"@types/bcryptjs": "^2.4.6",
5454
"@vercel/analytics": "^1.5.0",
55+
"@vercel/speed-insights": "^1.2.0",
5556
"bcryptjs": "^3.0.3",
5657
"class-variance-authority": "^0.7.1",
5758
"clsx": "^2.1.1",

src/app/layout.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { Toaster } from "@/components/ui/sonner";
44
import { ThemeProvider } from "next-themes";
55
import { Providers } from "@/components/providers";
66
import { Analytics } from "@vercel/analytics/react";
7+
import { SpeedInsights } from "@vercel/speed-insights/next";
78
import "./globals.css";
89

910
const geistSans = Geist({
@@ -67,6 +68,7 @@ export default function RootLayout({
6768
</ThemeProvider>
6869
</Providers>
6970
<Analytics />
71+
<SpeedInsights />
7072
</body>
7173
</html>
7274
);

src/components/coupons/coupons-list.tsx

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -274,10 +274,7 @@ export function CouponsList() {
274274
open={isCreateOpen}
275275
onOpenChange={setIsCreateOpen}
276276
onSuccess={() => {
277-
toast({
278-
title: 'Coupon created',
279-
description: 'New discount code has been created successfully',
280-
});
277+
toast.success('New discount code has been created successfully');
281278
}}
282279
/>
283280
</>

0 commit comments

Comments
 (0)