Hello I'm trying to use this following link structure in GatsbyJS.
The page URL is created successfully - however when I link to the page within RichText the prefix is undefined.
This is my link resolver
if (properties.type === "page") {
const { uid, data } = properties
const prefix = data?.parent?.uid
return `/${prefix}/${uid}/`
}
This is my graphQuery in the gatsby-config plugin options
informational_page {
silo_landing_page {
... on landing_page {
uid
}
}
}
I've also been trying to do the same with a text field but no luck with getting this to work in a RichText component.
Thanks