nuxt-expert
Skill3 starsChanged 14 days agoMITView on GitHub
Nuxt 4 / Nuxt 3 conventions — SSR/SSG/hybrid rendering via routeRules, app/ directory structure, useFetch/useAsyncData data fetching, file-based routing, layouts, Nitro server routes, runtimeConfig env. Load when the project uses Nuxt (nuxt.config.ts, app/ or root pages/ directory, server/ handlers); also for SEO meta, hydration, deployment tuning.
- Reads credentials
In this repository13 other files it gives its agents.
- AGENTS.mdAGENTS.md
- astro-expertSkill
- bulma-expertSkill
- code-reviewSkill
- frontend-accessibilitySkill
- performance-optimizerSkill
- security-auditSkill
- seo-auditSkill
- systematic-debuggingSkill
- update-documentationSkill
- vue-expertSkill
- web-designSkill
- website-analyzerSkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 1 is distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 80
Read config via useRuntimeConfig() — not process.env at runtime
- Very specific: line 88
Use Vuex — use Pinia or useState
- Very specific: line 89
Put secrets in runtimeConfig.public
- Very specific: line 92
Keep pages/components/composables in root for Nuxt 4 project — use app/ directory
- Distinctive: line 96
When implementing Nuxt features, provide:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Nuxt Expert
Senior Nuxt specialist, Vue.js meta-framework: SSR, SSG, hybrid rendering, Nitro server. Structure derived from vue-expert skill (MIT).
Builds on Vue 3: pair with skill
vue-expertfor Composition API, components, Pinia. Pair with skillbulma-expertwhen project uses Bulma — no duplication.
Core Workflow
- Analyze requirements - render mode per route (SSR/SSG/SPA/hybrid), data needs, auth, SEO
- Design architecture - app/ structure, pages, layouts, composables, Nitro routes
- Implement - auto-imports,
useFetch/useAsyncData, file-based routing - Validate -
nuxi typecheck+nuxt build; verify SSR + hydration - Optimize - routeRules caching/rendering, payload extraction, lazy hydration, bundle analysis
- Test - Vitest +
@nuxt/test-utils; e2e Playwright
Reference Guide
Load detailed guidance based on context:
| Topic | Reference | Load When |
| Structure & auto-imports | references/structure.md | app/ vs root dirs, ~/ alias, srcDir, directory conventions |
| Pages, layouts, middleware | references/routing.md | File-based routing, dynamic routes, definePageMeta, guards |
| Data fetching | references/data-fetching.md | useFetch, useAsyncData, caching, refresh, payload |
| Rendering modes & hydration | references/rendering.md | SSR/SSG/SPA/hybrid, routeRules, hydration mismatch, ClientOnly |
| Nitro server | references/server-nitro.md | server/api, event handlers, runtimeConfig, cookies, caching |
| State | references/state.md | useState, Pinia integration, SSR-safe shared state |
| SEO & metadata | references/head-seo.md | useHead, useSeoMeta, Open Graph, canonical |
| Config, build & deploy | references/build-config.md | nuxt.config, TypeScript strict, modules, Vite tuning, nitro preset |
Quick Example
Minimal Nuxt 4 page with SSR-safe data fetching + typed props:
<!-- app/pages/users/[id].vue (Nuxt 4) / pages/users/[id].vue (Nuxt 3) -->
<script setup lang="ts">
interface User {
id: number
name: string
email: string
}
const route = useRoute()
// SSR-safe: fetched on server, reused for hydration, deduped by key
const { data: user, pending, error, refresh } = await useFetch<User>(`/api/users/${route.params.id}`)
useSeoMeta({
title: () => `User: ${user.value?.name ?? 'Loading'}`,
description: 'User profile page'
})
</script>
<template>
<div>
<div v-if="pending">Loading…</div>
<div v-else-if="error">{{ error.message }}</div>
<div v-else-if="user">
<h1>{{ user.name }}</h1>
<a :href="`mailto:${user.email}`">{{ user.email }}</a>
<button @click="refresh">Refresh</button>
</div>
</div>
</template>Constraints
MUST DO
useFetch/useAsyncDatafor data that must exist on server or survive hydration — never fetch inonMountedfor initial SSR data- Nuxt auto-imports (composables, components, utils) over manual imports from app code
- Server-only code in
server/— never importserver/utils from client code - Read config via
useRuntimeConfig()— notprocess.envat runtime typescript: { strict: true }, keep pages/components typed<ClientOnly>or hydration strategies for browser-only fragmentsdefinePageMeta()for per-route layout, middleware, route rules metadata
MUST NOT DO
- Access
window/documentunconditionally in<script setup>(SSR runs server-side) - Use Vuex — use Pinia or
useState - Put secrets in
runtimeConfig.public - Navigate with
window.location— usenavigateTo()/useRouter() - Register components manually when auto-import covers them
- Keep pages/components/composables in root for Nuxt 4 project — use
app/directory
Output Templates
When implementing Nuxt features, provide:
- Page + any layout with
definePageMeta()+ typed data fetching - Composable in
app/composables/when reusable logic exists (auto-imported) - Nitro handler in
server/api/when endpoint needed nuxt.config.tssnippet for rendering modes, modules, runtimeConfig- Brief explanation of rendering mode + data-fetching decision
Knowledge Reference
Nuxt 4 / Nuxt 3, SSR/SSG/SPA/hybrid via routeRules, Nitro server, useFetch/useAsyncData/useLazyFetch, file-based routing, layouts, middlewares, useState, Pinia, useHead/useSeoMeta, runtimeConfig, TypeScript strict, Vite integration, module ecosystem, @nuxt/test-utils
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

