I'm currently testing the experimental server actions feature in Next.js. Once this feature is enabled Next.js uses React's experimental build. This however results in hydration failed error messages when using custom HTML tags with a dash like `my-tag` in JSX. The server response does not include any output for this tag and its children. Replacing the custom tag with a regular tag like `<div>` works completely fine.

I previously reported this issue at vercel/next.js#51141 where they suspect this to be an issue within React itself.

React version: Experimental

## Steps To Reproduce

1. Install latest next.js: npx create-[next-app](https://linear.app/vercel/issue/NEXT-app)@latest
2. Enable server actions in next.config.js
3. Wrap {children} in root layout with custom HTML tag like `<my-tag>`

Link to code example:
https://github.com/mritzerfeld/next-server-action-with-custom-tag

## The current behavior
Server-generated contents with custom HTML tags do no produce any output for such.

## The expected behavior
Server-generated contents within custom HTML tags to be included in server response, as using Next without server actions or with regular HTML tags.

},
  moduleUnknownResources: {
    [asType: string]: {
      [href: string]: Preloaded,
    },
  },
  moduleScriptResources: {
    [key: string]: Exists | Preloaded | PreloadedWithCredentials,
  },
};
const dataElementQuotedEnd = stringToPrecomputedChunk('"></template>');
const startInlineScript = stringToPrecomputedChunk('<script>');
const endInlineScript = stringToPrecomputedChunk('</script>');
const startScriptSrc = stringToPrecomputedChunk('<script src="');
const startModuleSrc = stringToPrecomputedChunk('<script type="module" src="');
const scriptNonce = stringToPrecomputedChunk('" nonce="');
const scriptIntegirty = stringToPrecomputedChunk('" integrity="');
const scriptCrossOrigin = stringToPrecomputedChunk('" crossorigin="');
const endAsyncScript = stringToPrecomputedChunk('" async=""></script>');
/**
 * This escaping function is designed to work with bootstrapScriptContent and importMap only.
 * because we know we are escaping the entire script. We can avoid for instance
 * escaping html comment string sequences that are valid javascript as well because
 * if there are no sebsequent <script sequences the html parser will never enter
 * script data double escaped state (see: https://www.w3.org/TR/html53/syntax.html#script-data-double-escaped-state)
 *
 * While untrusted script content should be made safe before using this api it will
 * ensure that the script cannot be early terminated or never terminated state
 */
function escapeBootstrapAndImportMapScriptContent(scriptText: string) {