v2.8.0
What's Changed
v-drupal-markupdirective: hydration-safe rendering of Drupal markup by @loki in #515 — fixes #514- fix: Keep redirect payloads in the page cache so SPA repeat visits follow CE-API redirects by @loki in #509
- Dev-dependency updates: vite 7.3.6, ws 8.21.2, svgo 4.0.2, shell-quote 1.10.0, tar 7.5.22, brace-expansion 1.1.18, actions/setup-node v7 (#508, #510–#512, #516–#518)
⚠️ Upgrade notes: update your drupal-markup component
Since vue 3.5.39, hydration re-applies v-html content over the live DOM (vuejs/core#15138): every child node of the markup wrapper is recreated when hydration runs, and anything that happened in that DOM beforehand is lost — most importantly text a visitor typed into a Drupal form before hydration finished, but also lazyloaded image swaps and attached listeners. nuxt ≥ 4.4 already resolves to an affected vue version on any lockfile refresh, so this can hit you without a Nuxt upgrade.
This release registers the v-drupal-markup directive app-wide: the server renders the markup, hydration adopts the existing DOM untouched, fresh client-side mounts render normally, and genuine content changes still update.
The module update alone is not enough. Your drupal-markup component was scaffolded into the project and is never overwritten. If you haven't customized it, take the fresh copy from the module:
cp node_modules/nuxtjs-drupal-ce/playground/components/global/drupal-markup.vue \
components/global/drupal-markup.vueor remove it and re-run the init script (it only restores missing files, the rest of your project is untouched):
rm components/global/drupal-markup.vue
npx nuxt-drupal-ce-initIf you have customized the component, apply the one-attribute change by hand:
- <div v-if="content" style="display: contents" v-html="content" />
+ <div v-if="content" v-drupal-markup="content" style="display: contents" />Custom components: anywhere else your project renders server-delivered Drupal HTML with v-html, replace it with v-drupal-markup the same way — same binding, drop-in.
Without these edits nothing changes: your project keeps the 2.7 behavior, including the form-input wipe on vue ≥ 3.5.39.
See the README for the directive's semantics, trust model (identical to v-html — trusted server HTML only), and the Teleport pattern for interactive widgets inside rendered markup.
Full Changelog: v2.7.0...v2.8.0