Skip to content

Comments

feat: add nuxt-actions module#1403

Open
billymaulana wants to merge 3 commits intonuxt:mainfrom
billymaulana:feat/add-nuxt-actions
Open

feat: add nuxt-actions module#1403
billymaulana wants to merge 3 commits intonuxt:mainfrom
billymaulana:feat/add-nuxt-actions

Conversation

@billymaulana
Copy link

@billymaulana billymaulana commented Feb 20, 2026

Linked issue

resolves #1407

Type of change

  • ✨ New feature (a non-breaking change that adds functionality)

Description

Adds nuxt-actions to the Nuxt modules listing.

nuxt-actions — Type-safe server actions for Nuxt with Standard Schema validation, middleware composition, and reactive client composables. Works on top of Nuxt's native server routes (defineEventHandler from h3) — no extra protocol layer.

Server:

  • defineAction with input/output schema validation
  • createActionClient builder pattern with middleware composition
  • defineStreamAction for SSE streaming via h3 createEventStream
  • defineMiddleware / createMiddleware for reusable middleware

Client:

  • useAction with reactive status tracking, retry/backoff, request deduplication, debounce/throttle
  • useOptimisticAction with race-safe rollback
  • useActionQuery wrapping useAsyncData for SSR/caching
  • useStreamAction for real-time SSE consumption
  • useFormAction with v-model binding and field-level errors
  • invalidateActions / clearActionCache for cache management

Validation: Standard Schema v1 — Zod (≥3.24), Valibot (≥1.0), ArkType (≥2.1)

DX: E2E type inference via #actions virtual module, HMR type regeneration, Nuxt DevTools tab, zero config auto-imports

Security: Prototype pollution protection, error message sanitization, hasOwnProperty-based error detection, double next() prevention, malformed JSON detection

Quality: 100% TypeScript, 32 compile-time type tests, comprehensive unit/type/integration test suite

Links

Compatibility

Nuxt 3 (≥3.7) and Nuxt 4

@coderabbitai
Copy link

coderabbitai bot commented Feb 20, 2026

📝 Walkthrough

Walkthrough

Added a new YAML descriptor at modules/nuxt-actions.yml for a Nuxt module named nuxt-actions. The file provides metadata fields: description, repository, npm package, icon, GitHub, website, learn_more, category, type, a single maintainer entry, compatibility set to ^3.7.0 || ^4.0.0, and an empty requires object. No source logic or exported/public entity declarations were changed.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title 'feat: add nuxt-actions module' clearly and concisely describes the main change—adding a new Nuxt module to the listing.
Linked Issues check ✅ Passed The PR meets all coding requirements from issue #1407: it adds the nuxt-actions module descriptor with proper metadata (repository, npm, compatibility, maintainers) as requested.
Out of Scope Changes check ✅ Passed All changes in the PR are directly in-scope—the single file addition (modules/nuxt-actions.yml) contains only the module descriptor requested in issue #1407 with no extraneous changes.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Description check ✅ Passed The pull request description clearly explains the purpose of adding nuxt-actions to the Nuxt modules listing, provides detailed information about the module's features, and directly relates to the changeset.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings (stacked PR)
  • 📝 Generate docstrings (commit on current branch)
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Module Listing Request]: nuxt-actions

1 participant