Skip to content
This repository was archived by the owner on Apr 4, 2019. It is now read-only.
This repository was archived by the owner on Apr 4, 2019. It is now read-only.

[Question] Variable HTML content DOM cache/diff optimization? #446

@zhuoqiang

Description

@zhuoqiang

Hi,

Not sure if I understand it correctly, AFAIK, HTMLBar/Glimmer only parse and cache the DOM structure of the Handelbars template, but not the rendered HTML itself.

Here's a special usecase to tell the difference:

<div>
{{toHTML someMarkdownContent}}
</div>

while this handlerbar template itself is simple and easy to cache/diff for glimmer, the inner html generated by {{toHTML someMarkdownContent}} maybe quite complex.

I'm wondering if the same DOM cache/diff optimization could also be applied to the dynamica HTML content generated by {{toHTML someMarkdownContent}}

In other words, right now, whatever the someMarkdownContent changes, the whole generated HTML dom need to be rerendered. Could we check the dynamica generated HTML code and only update the dom node which has changed, just like what glimmer did to handlebar template?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions