Skip to content

fix: Add "defer-and-hydrate" and "hydrate" as templateOptions #7173

@janechu

Description

@janechu

🐛 Bug Report

Using defineAsync() bypasses the fromCustomElement in FASTElement where this templateOption was being used. This should instead be interpreted by the TemplateElement in @microsoft/fast-html.

The following options should work:

  • Passing "defer-and-hydrate" should add defer-hydration and needs-hydration boolean attributes before defining the custom element with the custom element registry
  • Passing "hydrate" should add needs-hydration attribute before defining the custom element with the custom element registry
  • Passing nothing should cause the ElementController to be used instead

Metadata

Metadata

Assignees

Labels

area:ssrPertains to SSR.

Type

Projects

Status

In Progress

Relationships

None yet

Development

No branches or pull requests

Issue actions