feat: merge Explore and Activity Feed, unify recipe cards
Explore and Feed covered overlapping ground (recommendations, following, trending) in two separate places with three different card designs. Explore now hosts Discover/Following/For You tabs, and every recipe card everywhere on the page matches the Recipes page's cover-photo card instead of the old text-only search result. v0.36.0
This commit is contained in:
@@ -1,19 +1,5 @@
|
||||
import type { Metadata } from "next";
|
||||
import { headers } from "next/headers";
|
||||
import { auth } from "@/lib/auth/server";
|
||||
import { db, userFollows, eq } from "@epicure/db";
|
||||
import { FeedPageContent } from "@/components/feed/feed-page-content";
|
||||
import { redirect } from "next/navigation";
|
||||
|
||||
export const metadata: Metadata = {};
|
||||
|
||||
export default async function FeedPage() {
|
||||
const session = await auth.api.getSession({ headers: await headers() });
|
||||
if (!session) return null;
|
||||
|
||||
const followedRows = await db
|
||||
.select({ followingId: userFollows.followingId })
|
||||
.from(userFollows)
|
||||
.where(eq(userFollows.followerId, session.user.id));
|
||||
|
||||
return <FeedPageContent followedCount={followedRows.length} />;
|
||||
export default function FeedPage() {
|
||||
redirect("/explore");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user