From 2cc937ba87d509e9556b771864e91d425e792f08 Mon Sep 17 00:00:00 2001 From: Richard Poelderl Date: Wed, 15 Mar 2023 21:08:29 +0100 Subject: [PATCH] chore: Deactivate automatic link prefetching for `/blog` links (#7751) * disable prefetch on the `Tips` cards --- packages/ui/components/card/Card.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/ui/components/card/Card.tsx b/packages/ui/components/card/Card.tsx index 6b4a08e634..d4674a0c60 100644 --- a/packages/ui/components/card/Card.tsx +++ b/packages/ui/components/card/Card.tsx @@ -147,7 +147,10 @@ export function Card({ onClick={actionButton?.onClick} target="_blank" rel="noreferrer" - className="text-xs font-medium"> + className="text-xs font-medium" + // NextJS thinks this is an internal link and tries to prefetch it (also on hover), which fails + // TODO: Extract this into a constant to handle /docs & /developer as well + prefetch={!learnMore.href.startsWith("https://cal.com/blog")}> {learnMore.text} )}