Fix hydration with empty spread attributes (#4647)

* Fix hydration of empty spread attributes

* add a regression test

* fix doctest
This commit is contained in:
Evan Almloff authored and GitHub committed 2025-10-03 19:41:23 -07:00
1 parent f48aec7eff
commit 03801e1312
8 files changed
+94 -2

No files matched your search

@@ -0,0 +1,13 @@
// @ts-check
const { test, expect } = require("@playwright/test");
test("spread attributes hydrate", async ({ page }) => {
await page.goto("http://localhost:7979");
// Expect the page to contain the button
const counter = page.locator("#counter");
await expect(counter).toHaveText("Count: 0");
// Clicking on the button should increment the count
await counter.click();
await expect(counter).toHaveText("Count: 1");
});