JSideris / DOThtml

A human-friendly way to build highly-dynamic web pages in pure JavaScript.
2 stars 4 forks source link

Don't restyle on prop changes. #143

Closed JSideris closed 8 months ago

JSideris commented 1 year ago

This is a problem. Restyling should only happen to new elements that are created, not the entire component.

And ideally, we could be very intelligent about it. Rather than applying styles directly, store an array of style rules and run new elements within a component through the list of rules (if there is a match). Then perhaps we could bind specific rules to props to only update those rules rather than redoing all styles.

High priority.

JSideris commented 8 months ago

Overhauled props in v6. This is no longer an issue.