Skip to content

[Hydration] Detect mismatches when two render()d templates have similar HTML content #4867

Open
@nolanlawson

Description

@nolanlawson

Say you have two templates:

<!-- a.html -->
<template>
  <h1>a</h1>
</template>
<!-- b.html -->
<template>
  <h1>b</h1>
</template>

If you use render() to return one template on the client and another on the server, you would expect a hydration mismatch since the <h1>s have different content in this case.

However, this only works today when the static content optimization is disabled. When it's enabled (by default), we do not detect hydration mismatches and (worse) we render a even though the client wants b.

Repro: d0cd953

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bughydrationHaving to do with hydration after SSR

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions