-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Components will now never hydrate when the `defer-hydration` attribute is set. Hydration is only triggered when that attribute is removed or when a component is connected to the DOM without the attribute set. Two particular nuances here: 1. Components created imperatively will not trigger hydration unless they are connected to the DOM or `defer-hydration` is added and removed. The reason for this is because otherwise `document.createElement` would immediately trigger hydration before there is an opportunity to set `defer-hydration`. 2. Removing `defer-hydration` while a component is disconnected from the DOM still triggers hydration. This reason for this is to support components coming from a cloned template which would like to hydrate prior to being connected to the DOM.
- Loading branch information
Showing
3 changed files
with
87 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters