Scaffold a new component using Nuxt UI v4 patterns with proper typing and composition
Scaffolds Vue components using Nuxt UI v4 patterns with TypeScript and proper validation.
npx claudepluginhub secondsky/claude-skills<component-type> <name> [--path <dir>]Scaffold a new Vue component using Nuxt UI v4 patterns and components.
<component-type>: Type of component to scaffold:
form - Form with validationtable - Data table with sorting/paginationmodal - Modal dialog with formdashboard - Dashboard layoutchat - AI chat interfacepage - Page layout with hero/sectionscard - Card with content slotsdropdown - Dropdown menu with actions<name>: Component name in PascalCase (e.g., UserSettings)
--path <dir>: Output directory (default: components/)
Parse Component Type and Name Determine which Nuxt UI components to use.
Fetch Component Metadata Use MCP tools to get accurate props and slots.
Generate Component Based on Type
<script setup lang="ts">
import { z } from 'zod'
const schema = z.object({
// Define schema
})
type FormData = z.infer<typeof schema>
const state = reactive<Partial<FormData>>({})
async function onSubmit() {
// Handle submit
}
</script>
<template>
<UForm :state="state" :schema="schema" @submit="onSubmit">
<UFormField name="field" label="Field">
<UInput v-model="state.field" />
</UFormField>
<UButton type="submit">Submit</UButton>
</UForm>
</template>
<script setup lang="ts">
const columns = [
{ key: 'name', label: 'Name', sortable: true },
{ key: 'actions', label: '' }
]
const { data, pending } = await useFetch('/api/data')
</script>
<template>
<UTable :columns="columns" :rows="data" :loading="pending">
<template #actions-data="{ row }">
<UDropdownMenu :items="getActions(row)" />
</template>
</UTable>
</template>
<template>
<UDashboardGroup>
<UDashboardSidebar>
<UNavigationMenu :items="menuItems" />
</UDashboardSidebar>
<UDashboardPanel>
<template #header>
<UDashboardNavbar />
</template>
<template #body>
<slot />
</template>
</UDashboardPanel>
</UDashboardGroup>
</template>
<script setup lang="ts">
import { Chat } from '@ai-sdk/vue'
const chat = new Chat({ api: '/api/chat' })
const input = ref('')
function onSubmit() {
chat.sendMessage({ text: input.value })
input.value = ''
}
</script>
<template>
<UChatMessages :messages="chat.messages" :status="chat.status">
<template #content="{ message }">
<div>{{ message.content }}</div>
</template>
</UChatMessages>
<UChatPrompt v-model="input" @submit="onSubmit">
<UChatPromptSubmit :status="chat.status" />
</UChatPrompt>
</template>
<template>
<UPage>
<UPageHero
title="Page Title"
description="Page description"
:links="[{ label: 'Get Started', to: '/start' }]"
/>
<UPageSection>
<UPageGrid>
<UPageCard
v-for="item in items"
:key="item.id"
v-bind="item"
/>
</UPageGrid>
</UPageSection>
</UPage>
</template>
Add TypeScript Types Include proper type definitions for props/emits.
Write Component File
Save to specified path or components/<Name>.vue.