From d3e6a2caea8a002a85aff100e1ab2c047476cc91 Mon Sep 17 00:00:00 2001 From: wangmeng Date: Fri, 8 Mar 2024 17:25:36 +0800 Subject: [PATCH 1/2] feat: update --- web/middleware.ts | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/web/middleware.ts b/web/middleware.ts index c39fecd..5aabf79 100644 --- a/web/middleware.ts +++ b/web/middleware.ts @@ -1,10 +1,8 @@ -import { authMiddleware } from "@clerk/nextjs"; +import { authMiddleware } from '@clerk/nextjs' -// This example protects all routes including api/trpc routes -// Please edit this to allow other routes to be public as needed. // See https://clerk.com/docs/references/nextjs/auth-middleware for more information about configuring your Middleware -export default authMiddleware({}); +export default authMiddleware({}) export const config = { - matcher: ["/(dashboard)(.*)", "/api/(dashboard)(.*)"], -}; + matcher: ['/(dashboard)(.*)', '/api/(dashboard)(.*)'], +} From 93c8248bab6e49a4baadd508f89fd904b7cac834 Mon Sep 17 00:00:00 2001 From: wangmeng Date: Fri, 8 Mar 2024 17:51:25 +0800 Subject: [PATCH 2/2] feat: update --- web/app/(frontend)/page.tsx | 42 ++++++++++++++++++------------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/web/app/(frontend)/page.tsx b/web/app/(frontend)/page.tsx index 1431b13..a9d0d27 100644 --- a/web/app/(frontend)/page.tsx +++ b/web/app/(frontend)/page.tsx @@ -1,32 +1,32 @@ -import { getRandRows, getRecommendedRows, getTotalCount } from "../models/gpts"; +import { getRandRows, getRecommendedRows, getTotalCount } from '../models/gpts' -import Brand from "@/app/components/Brand"; -import Categories from "@/app/components/Categories"; -import { Gpts } from "@/app/types/gpts"; -import GptsList from "@/app/components/GptsList"; -import { Metadata } from "next"; -import ProductHunt from "@/app/components/ProductHunt"; -import Search from "@/app/components/Search"; -import Tab from "../components/Tab"; -import Tips from "@/app/components/Tips"; -import { getPromotedGpts } from "../models/order"; +import Brand from '@/app/components/Brand' +import Categories from '@/app/components/Categories' +import { Gpts } from '@/app/types/gpts' +import GptsList from '@/app/components/GptsList' +import { Metadata } from 'next' +import ProductHunt from '@/app/components/ProductHunt' +import Search from '@/app/components/Search' +import Tab from '../components/Tab' +import Tips from '@/app/components/Tips' +import { getPromotedGpts } from '../models/order' -export const maxDuration = 120; +export const maxDuration = 120 export async function generateMetadata(): Promise { return { - title: "Featured GPTs in Third-party GPT store | GPTs Works", + title: 'Featured GPTs in Third-party GPT store | GPTs Works', alternates: { canonical: `${process.env.WEB_BASE_URI}`, }, - }; + } } export default async () => { - const promoted_gpts = await getPromotedGpts(); - const recommended_gpts = await getRecommendedRows(1, 100); + const promoted_gpts = await getPromotedGpts() + const recommended_gpts = await getRecommendedRows(1, 100) - const gpts_count = await getTotalCount(); + const gpts_count = await getTotalCount() return ( <> @@ -37,10 +37,10 @@ export default async () => { {/* */} {promoted_gpts && } - {/*
-

Top Used GPTs

+ {/*
+

Top Used GPTs

*/} {recommended_gpts && } - ); -}; + ) +}