Astro Template Hierarchy with URQL
In this example we show how to implement the WP Template Hierarchy in Astro for use with a Headless WordPress backend using WPGraphQL. We use URQL for all routing and fetching page content.
Getting Started
Section titled “Getting Started”- Run
npm run example:setupto install dependencies and configure the local WP server. - Run
npm run example:startto start the WP server and Astro development server.
Trouble Shooting
Section titled “Trouble Shooting”To reset the WP server and re-run setup you can run npm run example:prune and confirm “Yes” at any prompts.