react.dev icon indicating copy to clipboard operation
react.dev copied to clipboard

Improve documentation for useSyncExternalStore

Open pwbriggs opened this issue 1 year ago • 5 comments
trafficstars

Clarify the "I’m getting an error: “The result of getSnapshot should be cached” section of the useSyncExternalStore API reference documentation.

I put some notes about why the documented error occurs in a <DeepDive> section. It focuses on the details of comparison in JavaScript. I'm not sure if this is the intended use of deep dive sections (for example, how much prior knowledge about JavaScript do we assume the reader has? Who is the intended audience for the deep dive sections in the API reference? How well-known are the details of comparing objects in JavaScript?), but, in any case, I think this is at least an improvement.

pwbriggs avatar Jan 04 '24 22:01 pwbriggs

Size changes

📦 Next.js Bundle Analysis for react-dev

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

github-actions[bot] avatar Jan 04 '24 22:01 github-actions[bot]

Hey @pwbriggs, unrelated to this PR, I can't find a way to contact you. Can you email me or DM me on twitter? I appreciate all you do on the docs and I'd like to upgrade your permissions to be a maintainer if you're interested :)

rickhanlonii avatar Feb 11 '24 15:02 rickhanlonii

Sure, thanks for the invitation! Do you have an email address you're willing to share? Do you have access to [email protected]'s inbox?

pwbriggs avatar Feb 14 '24 05:02 pwbriggs

Same as my GH handle at gmail

rickhanlonii avatar Feb 14 '24 14:02 rickhanlonii

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
19-react-dev ❌ Failed (Inspect) May 12, 2024 4:04am
react-dev ✅ Ready (Inspect) Visit Preview May 12, 2024 4:04am

vercel[bot] avatar May 11 '24 04:05 vercel[bot]