PrismicLink accepts InternalLink (Next Link component).
Type '(props: LinkProps) => Element' is not assignable to type 'ElementType<DetailedHTMLProps<AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>> | undefined'.
Type '(props: LinkProps) => Element' is not assignable to type 'FunctionComponent<DetailedHTMLProps<AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>>'.
Types of parameters 'props' and 'props' are incompatible.
Type 'DetailedHTMLProps<AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>' is not assignable to type 'LinkProps'.
Types of property 'href' are incompatible.
Type 'string | undefined' is not assignable to type 'string'.
Type 'undefined' is not assignable to type 'string'.ts(2322)
PrismicLink.d.ts(45, 5): The expected type comes from property 'internalComponent' which is declared here on type 'IntrinsicAttributes & (PrismicLinkProps<DetailedHTMLProps<AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement>, DetailedHTMLProps<...>> & { ...; })'
Versions
@prismicio/client: 7.16.0,@prismicio/helpers: 2.3.9,@prismicio/next: 2.0.0,@prismicio/react: 3.0.0,@prismicio/slice-simulator-react: 0.2.3,react: 19.0.0next: 15.1.7Reproduction
Additional Details
Steps to reproduce
I followed this guide in my Next.js (Pages Router) app. Very confusing to be honest.
What is expected?
PrismicLink accepts InternalLink (Next Link component).
What is actually happening?