I’m trying to run this query:
const page = await $prismic.api.query([ $prismic.predicates.at('document.type', 'homepage'), $prismic.predicates.at('my.homepage.main_projects.project', homeId), ])
In the homepage, I have a group field (main_projects)
Within the group field, I have a relationship field (API ID: main_project) linking to a custom type (API Id: project)
I’m trying to get data of the custom type document that is added with the relationship field in the group field.
However, the query does not return any results.
If I run this:
const page = await $prismic.api.query([ $prismic.predicates.at('document.type', 'homepage'), ])
It returns the homepage data but I don’t seem to get the data of the custom type added in the relationship in the group