Closed zto-sbenning closed 1 year ago
You are right for Next@13, but next-translate-routes does not support next@13 yet.
With next@12, you cannot set target
attribute to Link
, you must give it to the <a>
child.
I take note not to forget to update this type when updating next-translate-routes to support next@13, but there is a lot to work on. (If you are willing to help on this...)
The following code is not valid on typescript 4.8.4:
It generate the error:
target="_blank"
causes the error.It might be because of the declaration of
next-translate-routes/link
:as
LinkProps
seems to only be the internal props fornext/link
and those does not includesReact.AnchorHTMLAttributes<HTMLAnchorElement>
:I might be all wrong, but I think the declaration should include
and not only
LinkProps
.