smith-nuxt

Standardize auto-import stubbing, environment variable conventions, and middleware testing in Nuxt 3 projects.

1|Updated Nov 25, 2025
One-click install
npx skills add https://github.com/tianjianjiang/smith --skill smith-nuxt
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: smith-nuxt
Source: https://github.com/tianjianjiang/smith/tree/main/smith-nuxt
Command: npx skills add https://github.com/tianjianjiang/smith --skill smith-nuxt

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Nuxt 3 development can be slowed by inconsistent testing setups and unclear environment conventions. This Skill standardizes auto-import stubbing, environment variable naming, and middleware testing patterns to improve reliability and clarity across Nuxt projects.

Core Features & Use Cases

  • Auto-import stubbing: Establishes safe, predictable globals for tests before module imports.
  • Environment variable conventions: Documents and enforces client/server prefixes (NUXT_PUBLIC_* for client, NUXT_* for server) and secure handling.
  • Middleware testing patterns: Provides guidance for testing Nuxt middlewares and server routes in isolation.

Quick Start

Set up a Nuxt 3 project configured for auto-import stubbing, environment variable conventions, and middleware testing.

Frequently Asked Questions about smith-nuxt

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I stub auto-imports in Nuxt 3 tests?

To stub auto-imports in Nuxt 3 tests, you must establish safe, predictable globals before module imports. This standardizes testing setups to improve reliability and prevent inconsistent behavior across your Nuxt projects.

What environment variable conventions should I use in Nuxt 3?

Nuxt 3 environment variable conventions require prefixing client variables with NUXT_PUBLIC_* and server variables with NUXT_*. Enforcing these prefixes ensures secure handling and clarity across development and testing workflows.

How do I test middleware and server routes in Nuxt 3?

Testing Nuxt 3 middleware and server routes involves isolating them using standardized testing patterns. This approach provides guidance for validating middleware behavior securely and predictably within your development environment.

Do I need TypeScript to use standardized testing patterns in Nuxt 3?

Yes, TypeScript usage is a strict prerequisite for applying these standardized testing patterns in Nuxt 3. Enforcing TypeScript ensures reliable auto-import stubbing and consistent environment variable handling across your project.

Why does my Nuxt 3 testing setup fail with inconsistent environment variables?

Nuxt 3 testing setups fail due to unclear environment variable conventions and inconsistent auto-import stubbing. Standardizing these patterns ensures reliable module imports and secure client/server variable handling across workflows.