fast icon indicating copy to clipboard operation
fast copied to clipboard

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

Open janechu opened this issue 7 months ago • 0 comments

🐛 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

janechu avatar Sep 05 '25 21:09 janechu