Skip to content

wpnuxt/wpnuxt-core

Repository files navigation

This module is still being developed and not ready for production usage yet. There will be many smaller alpha releases the coming weeks, often with breaking changes.

I am working towards a stable release. And will inform about it here

WPNuxt

npm version npm downloads License Nuxt

Nuxt module for using WordPress as a headless CMS with a Nuxt 3 frontend

Features

  • Content is fetched from WordPress using server-side GraphQL api calls
  • Support for (Gutenberg Blocks) by adding the separate @wpnuxt/blocks, which uses WPEngine's wp-graphql-content-blocks and a set of custom vue components

Quick Setup

Install the module to your Nuxt application with one command:

npx nuxi module add @wpnuxt/core

And connect WPNuxt to your wordpress installation in your nuxt.config.ts:

wpNuxt: {
    wordpressUrl: 'https://yourwordpress.domain.com'
},

That's it! You can now use the WPNuxt module in your Nuxt app ✨

Development

# Install dependencies
pnpm install

# Generate type stubs
pnpm run dev:prepare

# Develop with the playground
pnpm run dev

# Build the playground
pnpm run dev:build

# Run ESLint
pnpm run lint

# Run Vitest
pnpm run test
pnpm run test:watch

# Release new version
pnpm run release