This is the SvelteKit app from the "Headless WordPress with SvelteKit" talk given by Kellen Mace at the Svelte Summit conference in fall, 2021: https://www.youtube.com/watch?v=l0q3alPtoow
- Get a local WordPress site running locally, and install and activate the WPGraphQL plugin.
- Clone this repo down to your machine
cdinto the root directory of this project. Create a.env.localfile and define an environment variable like thisVITE_PUBLIC_WORDPRESS_API_URL=http://sveltesummit.local/graphql, replacing "http://sveltesummit.local" with the domain of your local WordPress site.- Run
npm install, thennpm run dev. Visithttp://localhost:3000in a browser to see your app.