Skip to content

Conversation

hzy
Copy link

@hzy hzy commented Jul 24, 2025

oldVnode is not exposed in options._diff, which makes it difficult to get the component instance in this hook (because newVNode usually does not have a _component property). This PR provides a new way to get the component instance in the update process, which can still work when, for example, parent and child components setState at the same time.

Copy link

github-actions bot commented Jul 24, 2025

📊 Tachometer Benchmark Results

Summary

A summary of the benchmark results will show here once they finish.

Results

The full results of your benchmarks will show here once they finish.

tachometer-reporter-action v2 for CI

@hzy hzy force-pushed the oldVNode_in_options_diff branch from 91a8593 to 721d9c1 Compare July 24, 2025 09:43
hzy added a commit to hzy/lynx-stack that referenced this pull request Jul 24, 2025
To compare: preactjs/preact@10.24.0...hzy:preact:lynx/v10.24.x, which means this is preactjs/preact#4849 landed on previous version `319c684e`
github-merge-queue bot pushed a commit to lynx-family/lynx-stack that referenced this pull request Jul 24, 2025
To compare:
preactjs/preact@10.24.0...hzy:preact:lynx/v10.24.x,
which means this is preactjs/preact#4849 landed
on previous version `319c684e`

<!--
  Thank you for submitting a pull request!

We appreciate the time and effort you have invested in making these
changes. Please ensure that you provide enough information to allow
others to review your pull request.

Upon submission, your pull request will be automatically assigned with
reviewers.

If you want to learn more about contributing to this project, please
visit:
https://github.com/lynx-family/lynx-stack/blob/main/CONTRIBUTING.md.
-->

<!-- The AI summary below will be auto-generated - feel free to replace
it with your own. -->

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **Bug Fixes**
* Improved internal handling of rendering lifecycle hooks for better
consistency and compatibility.

* **Chores**
  * Updated a dependency to a newer version for enhanced stability.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

## Checklist

<!--- Check and mark with an "x" -->

- [ ] Tests updated (or not required).
- [ ] Documentation updated (or not required).
- [ ] Changeset added, and when a BREAKING CHANGE occurs, it needs to be
clearly marked (or not required).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant