Star
1.1K
Nuxt SEO Pro
  • Nuxt Redirects
  • Nuxt Google Search Console
  • Nuxt Internal Links
  • Nuxt SEO Analyze
Save $170 on the presale now.

Introduction

By default, a Nuxt plugin is registered in your app that will register the root nodes for a WebSite and WebPage for you.

These are configured using Nuxt Site Config,

Site Config v2.2.18
770K
65
Powerful build and runtime shared site configuration for Nuxt modules.

The only configuration you may need to provide is the identity of your site.

Selecting An Identity

Selecting an identity makes sure the Default Schema.org is correctly linked to the author of the site.

There are two types of identities you can use: Organisation and Person`.

If the choice isn't clear, you can use the Organization identity as a default or read the Choosing an identity docs for more information.

Setting Identity

The simplest way to set up your identity is to set it in your nuxt.config using a string:

Organization
export default defineNuxtConfig({
  schemaOrg: {
    identity: 'Organization'
  }
})
Person
export default defineNuxtConfig({
  schemaOrg: {
    identity: 'Person'
  }
})

Providing Extra Identity Data

It's recommended to provide more information about your identity, such as the name, URL, logo and social media links.

Organization
// example for nuxt.com
export default defineNuxtConfig({
  schemaOrg: {
    identity: {
      type: 'Organization',
      name: 'NuxtJS',
      logo: '/logo.png', // will resolve to canonical URL + /logo.png
      sameAs: [
        'https://x.com/nuxt_js',
        'https://www.linkedin.com/showcase/nuxt-framework/',
        'https://github.com/nuxt'
      ]
    }
  }
})
Person
// example for harlanzw.com
export default defineNuxtConfig({
  schemaOrg: {
    identity: {
      type: 'Person',
      name: 'Harlan Wilton',
      image: '/profile.jpg',
      sameAs: [
        'https://x.com/harlan_zw',
        'https://github.com/harlan-zw',
        'https://harlanzw.com'
      ]
    }
  }
})
Did this page help you?