Nuxt AEO is a module for Nuxt that provides a simple way to implement AI Engine Optimization using Schema.org JSON-LD structured data.
It allows developers to easily add and manage schemas through composable functions with full TypeScript support.
Everything you need for AI Engine Optimization
Combine Schema.org simplicity with Nuxt composable power.
Build AI-optimized websites, from documentation pages to complex applications.
<script setup lang="ts">
const { data: article } = await useAsyncData('article', () => {
return queryCollection('articles').path('/my-article').first()
})
useSchema({
type: 'Article',
headline: article.value?.title,
datePublished: article.value?.date,
author: {
type: 'Person',
name: 'Author Name'
}
})
</script>
<template>
<article>
<h1>{{ article?.title }}</h1>
<ContentRenderer :value="article" />
</article>
</template>
Article Schema Example.
Learn how to use useSchema() composable to structure blog posts and articles with Article schema.
<script setup lang="ts">
useSchemaFaq({
mainEntity: [
{
name: 'What is the Nuxt AEO module?',
acceptedAnswer: {
text: 'Nuxt AEO is a Nuxt module that implements AI Engine Optimization (AEO) using Schema.org JSON-LD structured data. It helps AI models and search engines better understand website content.',
},
},
{
name: 'What Schema types are supported?',
acceptedAnswer: {
text: 'Nuxt AEO supports various Schema.org types including Person, Organization, Article, ItemList, and more. You can configure both global schemas and page-specific schemas through useSchema() and useSchemaFaq() composables.',
},
},
{
name: 'Can I use it immediately after installation?',
acceptedAnswer: {
text: 'Yes! Nuxt AEO can be used immediately after installation. Once you install the module and add it to nuxt.config.ts, you can define schemas using useSchema() or useSchemaFaq() composables. It provides default behavior without additional configuration.',
},
},
{
name: 'What is the difference between useSchemaFaq() and useSchema()?',
acceptedAnswer: {
text: 'useSchema() is used to define schemas that describe the main content of a page (e.g., Article, Person), while useSchemaFaq() is used to define metadata about the page itself (e.g., FAQPage, BreadcrumbList). You can use both composables together to structure both page content and metadata.',
},
},
],
})
</script>
<template>
<div>
<h1>Nuxt AEO</h1>
<!--Page Content-->
</div>
</template>
FAQPage Schema Example.
Learn how to use useSchemaFaq() composable to add FAQPage schema for better AI and search engine understanding.
Explore real-world examples of how to use Nuxt AEO with different schema types.