link: clear as property if link has no href (#1272)

This commit is contained in:
Masen Furer 2023-06-29 18:45:34 -07:00 committed by GitHub
parent bc5d5c61f2
commit 5d4f402987
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -51,7 +51,7 @@ class Link(ChakraComponent):
raise ValueError("Link without a child will not display")
elif href is None and len(children):
# Don't use a NextLink if there is no href.
props["as_"] = "Link"
props["as_"] = ""
if href:
props["href"] = href
return super().create(*children, **props)