Idk how to fix this error :/
Unanswered
Banana posted this in #help-forum
BananaOP
Error:
Code Snippet:
(Im using payloadCMS)
Type '({ token }: { req: PayloadRequest; token: string; user: any; }) => Element' is not assignable to type 'GenerateVerifyEmailHTML'.
Type 'Element' is not assignable to type 'string | Promise<string>'.Code Snippet:
generateEmailHTML: ({token}) => {
return PrimaryActionEmailHtml({
actionLabel: "Verify your account",
href: `${process.env.NEXT_PUBLIC_SERVER_URL}/verify-email?token=${token}`
(Im using payloadCMS)
3 Replies
BananaOP
PrimaryActionEmail:
https://pastebin.com/BhP9Y8q4
https://pastebin.com/BhP9Y8q4
BananaOP
bump
Laysan Albatross
thats an issue with your typing (typescript). You defined the type string for token but it receives something with the type Element.