diff --git a/packages/nuxt/src/app/components/island-renderer.ts b/packages/nuxt/src/app/components/island-renderer.ts index 8e77445742..6fc2fd479d 100644 --- a/packages/nuxt/src/app/components/island-renderer.ts +++ b/packages/nuxt/src/app/components/island-renderer.ts @@ -27,6 +27,6 @@ export default defineComponent({ console.log(e) }) - return () => createVNode(component || 'span', { ...props.context.props, 'nuxt-ssr-component-uid': '' }) + return () => createVNode(component || 'span', { ...props.context.props, 'data-island-uid': '' }) } }) diff --git a/packages/nuxt/src/app/components/nuxt-island.ts b/packages/nuxt/src/app/components/nuxt-island.ts index 60e023ce68..b129f88dea 100644 --- a/packages/nuxt/src/app/components/nuxt-island.ts +++ b/packages/nuxt/src/app/components/nuxt-island.ts @@ -1,5 +1,5 @@ import type { Component } from 'vue' -import { Fragment, Teleport, computed, createStaticVNode, createVNode, defineComponent, getCurrentInstance, h, nextTick, onMounted, ref, toRaw, watch } from 'vue' +import { Fragment, Teleport, computed, createStaticVNode, createVNode, defineComponent, getCurrentInstance, h, nextTick, onMounted, ref, toRaw, watch, withMemo } from 'vue' import { debounce } from 'perfect-debounce' import { hash } from 'ohash' import { appendResponseHeader } from 'h3' @@ -13,29 +13,29 @@ import { join } from 'pathe' import type { NuxtIslandResponse } from '../../core/runtime/nitro/renderer' import { useNuxtApp, useRuntimeConfig } from '../nuxt' import { prerenderRoutes, useRequestEvent } from '../composables/ssr' -import { getFragmentHTML, getSlotProps } from './utils' +import { getFragmentHTML } from './utils' // @ts-expect-error virtual file import { remoteComponentIslands, selectiveClient } from '#build/nuxt.config.mjs' const pKey = '_islandPromises' -const SSR_UID_RE = /nuxt-ssr-component-uid="([^"]*)"/ -const UID_ATTR = /nuxt-ssr-component-uid(="([^"]*)")?/ -const SLOTNAME_RE = /nuxt-ssr-slot-name="([^"]*)"/g -const SLOT_FALLBACK_RE = /
message: {{ message }}
Below is the slot I want to be hydrated on the client
Above is the slot I want to be hydrated on the client
@@ -166,7 +171,8 @@ describe('islandTransform - server and island components', () => { " @@ -234,13 +241,14 @@ describe('islandTransform - server and island components', () => { "