fix: conditionally pass href prop only when asLink is truthy

This commit is contained in:
Alan Buscaglia
2025-10-22 18:16:10 +02:00
parent 822b85dcdc
commit 3ca3432250
+1 -1
View File
@@ -86,7 +86,7 @@ export const CustomButton = React.forwardRef<
) => (
<Button
as={asLink ? Link : undefined}
href={asLink}
{...(asLink && { href: asLink })}
target={target}
type={type}
aria-label={ariaLabel}