Skip to content

chore(fast-html): use @microsoft/fast-build to build children fixture#7383

Merged
janechu merged 2 commits intomainfrom
users/janechu/update-fixture-to-use-fast-build-children
Apr 8, 2026
Merged

chore(fast-html): use @microsoft/fast-build to build children fixture#7383
janechu merged 2 commits intomainfrom
users/janechu/update-fixture-to-use-fast-build-children

Conversation

@janechu
Copy link
Copy Markdown
Collaborator

@janechu janechu commented Apr 4, 2026

Pull Request

📖 Description

Adds the children test fixture to @microsoft/fast-html and generates its index.html using @microsoft/fast-build, consistent with the other fixtures (attribute, binding, event, ref, slotted, when, repeat, repeat-event).

The children fixture covers f-children attribute directives, which bind references to child DOM nodes in a FAST template (e.g. <ul>). Because f-children is client-side only, @microsoft/fast-build strips it from the rendered Declarative Shadow DOM while preserving the data-fe-c hydration binding count so the FAST runtime can allocate the correct number of binding slots.

The fixture also exercises f-repeat inside the f-children-annotated element, verifying that SSR correctly renders the repeated list items (Foo, Bar) from the state while stripping the client-only directive.

The entry element in entry.html has no binding attributes — root JSON state is passed implicitly to entry-level custom elements by @microsoft/fast-build.

🎫 Issues

No open issues directly addressed.

📑 Test Plan

  • npm run build:fixtures in packages/fast-html runs cleanly and regenerates children/index.htmlf-children is stripped from the shadow DOM output, data-fe-c binding annotation is preserved, the f-repeat items are fully rendered, and no list attribute appears on the entry element.
  • All other fixture outputs are unchanged.

✅ Checklist

General

  • I have included a change request file using $ npm run change
  • I have added tests for my changes.
  • I have tested my changes.
  • I have updated the project documentation to reflect my changes.
  • I have read the CONTRIBUTING documentation and followed the standards for this project.

⏭ Next Steps

  • Add a Playwright spec file (children.spec.ts) covering hydration of the f-children fixture to verify client-side child node reference assignment after SSR.

@janechu janechu force-pushed the users/janechu/update-fixture-to-use-fast-build-children branch from 39118a8 to e5b3d7b Compare April 7, 2026 05:01
@janechu janechu marked this pull request as ready for review April 7, 2026 05:01
@janechu janechu marked this pull request as draft April 7, 2026 05:05
janechu and others added 2 commits April 7, 2026 20:19
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Rebase onto main (includes repeat, repeat-event, when fixtures).
Resolved build-fixtures.js conflict by appending 'children' to the
full fixture list.

Remove list="{{list}}" from entry.html — state is passed implicitly
from the root JSON. Fixture regenerated: list attribute stripped from
the entry element opening tag.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@janechu janechu force-pushed the users/janechu/update-fixture-to-use-fast-build-children branch from e5b3d7b to 19ece4a Compare April 8, 2026 03:20
@janechu janechu marked this pull request as ready for review April 8, 2026 03:21
@janechu janechu merged commit 145668d into main Apr 8, 2026
14 checks passed
@janechu janechu deleted the users/janechu/update-fixture-to-use-fast-build-children branch April 8, 2026 03:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant