Kirby's sample site β but rewritten headless with Nuxt 3!
Explore the kit live Β»
This repository is a port of the Kirby Starter Kit to Nuxt 3. The content is fetched with the nuxt-kql
module from a headless Kirby instance.
This is my best practice solution to build a Nuxt 3 based frontend on top of Kirby in headless mode.
- π« Kirby Query Language with
nuxt-kql
- πͺ Component based Kirby Blocks
- π Global site data similiar to Kirby's
$site
- π³ Collections for pre-defined queries
- π SSR generated SEO meta data
- π Prettier & ESLint
- π’ Pre-configured VSCode settings
- π And much more!
- Enable Corepack using
corepack enable
- Install dependencies using
pnpm install
- Adapt the relevant environment variables:
# Base URL of the Kirby backend
KIRBY_BASE_URL=
# Token for bearer authentication
# See https://github.com/johannschopplich/kirby-headless-starter#bearer-token
KIRBY_API_TOKEN=
- Start the development server using
pnpm run dev
- Visit localhost:3000
βΉοΈ Enable Take Over Mode in Visual Studio Code.
Build the application for production with pnpm run build
.
Check out the deployment documentation.
Data is fetched within Suspense components to ensure pre-rendered state for the user and SEO. Thus, the initial server response time is increased by about 50β100 ms for the initial KQL page query. This might be a road blocker for you. You can always pre-render routes.
- getkirby.com β Get to know the CMS.
- Try it β Take a test ride with our online demo. Or download one of our kits to get started.
- Documentation β Read the official guide, reference and cookbook recipes.
- Issues β Report bugs and other problems.
- Feedback β You have an idea for Kirby? Share it.
- Forum β Whenever you get stuck, don't hesitate to reach out for questions and support.
- Discord β Hang out and meet the community.
- YouTube - Watch the latest video tutorials visually with Bastian.
- Twitter β Spread the word.
- Instagram β Share your creations: #madewithkirby.
MIT License Β© 2022 Johann Schopplich