diff --git a/src/app/api/compatibility/route.ts b/src/app/api/compatibility/route.ts index 3d47f6f..6f4b3ae 100644 --- a/src/app/api/compatibility/route.ts +++ b/src/app/api/compatibility/route.ts @@ -60,7 +60,7 @@ export async function GET(request: NextRequest) { const statusFilter = statusFilterRaw && VALID_STATUSES.includes(statusFilterRaw) ? statusFilterRaw : undefined; const seed = await readCompatibilitySeed(); - const mcpBySlug = new Map((mcpServers as any as McpServer[]).map((server) => [server.slug, server])); + const mcpBySlug = new Map((mcpServers as unknown as McpServer[]).map((server) => [server.slug, server])); const rows = seed.servers .map((row) => { diff --git a/src/app/mcp/mcp-client.tsx b/src/app/mcp/mcp-client.tsx index 0943079..3e57ad9 100644 --- a/src/app/mcp/mcp-client.tsx +++ b/src/app/mcp/mcp-client.tsx @@ -196,21 +196,21 @@ export function McpHubClient({ servers }: { servers: McpServer[] }) {

{/* Stats */} - {((server as any).stars || (server as any).installs || (server as any).framework) && ( + {(server.stars || server.installs || server.framework) && (
- {(server as any).stars && ( + {server.stars && ( - ⭐ {(server as any).stars.toLocaleString()} + ⭐ {server.stars.toLocaleString()} )} - {(server as any).installs && ( + {server.installs && ( - 📦 {(server as any).installs.toLocaleString()} + 📦 {server.installs.toLocaleString()} )} - {(server as any).framework && ( + {server.framework && ( - {(server as any).framework} + {server.framework} )}
@@ -311,21 +311,21 @@ export function McpHubClient({ servers }: { servers: McpServer[] }) {

{/* Stats */} - {((server as any).stars || (server as any).installs || (server as any).framework) && ( + {(server.stars || server.installs || server.framework) && (
- {(server as any).stars && ( + {server.stars && ( - ⭐ {(server as any).stars.toLocaleString()} + ⭐ {server.stars.toLocaleString()} )} - {(server as any).installs && ( + {server.installs && ( - 📦 {(server as any).installs.toLocaleString()} + 📦 {server.installs.toLocaleString()} )} - {(server as any).framework && ( + {server.framework && ( - {(server as any).framework} + {server.framework} )}
diff --git a/src/lib/data.ts b/src/lib/data.ts index b13700a..00ea46c 100644 --- a/src/lib/data.ts +++ b/src/lib/data.ts @@ -86,8 +86,8 @@ export type McpServer = { github?: string; author?: string; tags?: string[]; - - // Phase 1 stats + + // Stats (populated at runtime) stars?: number; installs?: number; framework?: string;