import { motion } from "framer-motion"; import React, { useState } from "react"; interface TechItem { name: string; description: string; category: "frontend" | "backend" | "database" | "tooling" | "core"; } const techStack: TechItem[] = [ { name: "TypeScript", description: "Type safety across the entire stack", category: "core", }, { name: "React", description: "JavaScript library for user interfaces", category: "frontend", }, { name: "TanStack Router", description: "Type-safe routing with file-based routes", category: "frontend", }, { name: "TanStack Query", description: "Powerful data synchronization", category: "frontend", }, { name: "Tailwind CSS", description: "Utility-first CSS framework", category: "frontend", }, { name: "shadcn/ui", description: "Re-usable UI components", category: "frontend", }, { name: "Hono", description: "Ultrafast web framework", category: "backend", }, { name: "tRPC", description: "End-to-end type-safe APIs", category: "backend", }, { name: "Better-Auth", description: "Modern authentication solution", category: "backend", }, { name: "Drizzle ORM", description: "TypeScript-first ORM", category: "database", }, { name: "Prisma", description: "Next-generation ORM", category: "database", }, { name: "SQLite + Turso", description: "Serverless SQLite with edge replication", category: "database", }, { name: "PostgreSQL", description: "Advanced open-source relational database", category: "database", }, { name: "Biome", description: "Fast formatter and linter", category: "tooling", }, { name: "Husky", description: "Git hooks made easy", category: "tooling", }, { name: "PWA", description: "Progressive Web App support", category: "tooling", }, { name: "Tauri", description: "Build desktop and mobile apps with web tech", category: "tooling", }, { name: "Docker", description: "Containerized deployments", category: "tooling", }, { name: "Turborepo", description: "Optimized build system for monorepos", category: "core", }, ]; const categoryIcons = { frontend: "🖥️", backend: "⚙️", database: "🗄️", tooling: "🔧", core: "⚡", }; export default function TechShowcase() { const [activeCategory, setActiveCategory] = useState(null); const categories = Array.from( new Set(techStack.map((item) => item.category)), ); const filteredTech = activeCategory ? techStack.filter((tech) => tech.category === activeCategory) : techStack; const groupedTech = !activeCategory ? categories.map((category) => ({ category, items: techStack.filter((tech) => tech.category === category), })) : null; return (
{categories.map((category) => ( ))}
{activeCategory && (
{filteredTech.map((tech) => (

{tech.name}

{tech.description}

{tech.category === "tooling" || tech.category === "database" ? ( {tech.name === "Drizzle ORM" || tech.name === "Prisma" || tech.name === "SQLite + Turso" || tech.name === "PostgreSQL" ? ( --{tech.name.toLowerCase().split(" ")[0]} ) : ( --{tech.name.toLowerCase()} )} ) : ( Included by default )}
))}
)} {!activeCategory && groupedTech && (
{groupedTech.map((group) => (
{categoryIcons[group.category as keyof typeof categoryIcons]}

{group.category}/

{group.items.map((tech) => (

{tech.name}

{group.category === "tooling" || tech.category === "database" ? "optional" : "core"}

{tech.description}

{group.category === "tooling" || tech.category === "database" ? tech.name === "Drizzle ORM" || tech.name === "Prisma" || tech.name === "SQLite + Turso" || tech.name === "PostgreSQL" ? `--${tech.name.toLowerCase().split(" ")[0]}` : `--${tech.name.toLowerCase()}` : "included by default"}
))}
))}
)}
$ npx create-better-t-stack {" "} —your-options
); }