Skip to content

docs: clarify that update() syncs the tree, not force re-render - #2616

Open
Hashim1999164 wants to merge 1 commit into
enzymejs:masterfrom
Hashim1999164:fix/update-jsdoc-sync-not-rerender
Open

docs: clarify that update() syncs the tree, not force re-render#2616
Hashim1999164 wants to merge 1 commit into
enzymejs:masterfrom
Hashim1999164:fix/update-jsdoc-sync-not-rerender

Conversation

@Hashim1999164

@Hashim1999164 Hashim1999164 commented Jul 23, 2026

Copy link
Copy Markdown

Summary

  • Align ReactWrapper#update and ShallowWrapper#update JSDoc with the API docs.
  • The previous "Forces a re-render" wording was misleading in IDEs; update() only syncs Enzyme's tree snapshot.
  • Notes that forcing a re-render should use wrapper.setProps({}), matching the existing docs.

Fixes #2494

Test plan

  • Confirmed JSDoc text matches docs/api/ReactWrapper/update.md and docs/api/ShallowWrapper/update.md
  • Spot-check IDE hover text on wrapper.update() after install from this branch

Align ReactWrapper and ShallowWrapper JSDoc with the API docs so IDE
tooltips match the documented behavior for issue enzymejs#2494.
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.

Documentation issue, mount -> update

1 participant