Skip to content

feat(date): support Vuetify StringDateAdapter via adapter: 'string' - #400

Merged
AndreyYolkin merged 1 commit into
mainfrom
fix/string-date-adapter-383
Nov 25, 2026
Merged

AndreyYolkin merged 1 commit into
mainfrom
fix/string-date-adapter-383

Conversation

@AndreyYolkin

Copy link
Copy Markdown
Contributor

Closes #383. Supersedes #387 — thanks to mikemikimike for the original implementation (credited as co-author); that PR was closed while waiting on re-review.

  • vuetifyOptions.date.adapter: 'string' → imports StringDateAdapter from the stable vuetify/date/adapters/string export and passes it as a class, like luxon/dayjs/moment, so Vuetify constructs it with { locale, formats } and locale changes flow through.
  • Guarded to Vuetify ≥ 3.9.0 (adapter added in vuetify#21174, absent in v3.8.12) with a clear build error on older versions.
  • loader.ts: 'string' no longer falls into the @date-io/* branch (which logged "not installed" and silently dropped the config) — via a small isBuiltinDateAdapter() helper.
  • Docs: 'string' added to the adapter list in guide/features/date.md.

Changes vs #387: the full Nuxt build fixture was replaced by unit tests (one loads the generated virtual module through Vite ssrLoadModule and asserts the export is the real StringDateAdapter class); the loader change is now covered too.

Tests: date tests 10/10; full suite green apart from the basic-vuetify3 fixture issue fixed in #399. Build ok.

🤖 Generated with Claude Code

Based on #387 by mikemikimike; replaces the Nuxt SSR fixture with a
unit-tested isBuiltinDateAdapter helper and documents the option.

Closes #383

Co-authored-by: mikemikimike <186855910+mikemikimike@users.noreply.github.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@AndreyYolkin
AndreyYolkin merged commit b3a9b68 into main Nov 25, 2026
2 checks passed
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.

Specify "string" for data adapter

1 participant