ethercreative / seo

SEO utilities including a unique field type, sitemap & redirect manager
MIT License
269 stars 96 forks source link

Add GraphQL support to Redirects #373

Open kan-erik opened 3 years ago

kan-erik commented 3 years ago

In a headless setup, is there any way to pull out all redirect rules from Craft via some endpoint?

alexjcollins commented 3 years ago

@dazy-erik Currently there isn't, although this is something we're considering as we're currently defining them all in our Next.js config 😅 and supporting them via the CMS would be ideal.

In the meantime, I think you should be able to use Andrew's fantastic plugin Retour, although we haven't tried it ourselves: https://nystudio107.com/docs/retour/using.html#graphql-query-support

kan-erik commented 3 years ago

I understand, and thank you for the tip.

Are redirects available as data so that they could be output via twig for example?