JedWatson / react-select

The Select Component for React.js
https://react-select.com/
MIT License
27.42k stars 4.1k forks source link

react-select v5.8.0: `Extra attributes from the server: aria-activedescendant` #5859

Open zhouhua opened 5 months ago

zhouhua commented 5 months ago

When react-select is used in SSR, an error may occur during browser rendering: Extra attributes from the server: aria-activedescendant. This should be a hydration problem.

I think it's caused by this line of code: https://github.com/JedWatson/react-select/blob/06e34882638d1526b9f5a1238bb567a3e9460ce5/packages/react-select/src/Select.tsx#L1724

It may be written in a useEffect to avoid differences in browser and server environments.

mefik1337 commented 4 months ago

any fix for now?

zhouhua commented 4 months ago

any fix for now?

https://github.com/JedWatson/react-select/pull/5860

waiting for code review

codingwithchris commented 2 months ago

Same issue here. Any progress on getting #5860 reviewed and/or doing a fix that resolves this holistically without the need for consumers to set an additional prop?

Screenshot 2024-04-10 at 1 01 43 PM

hannupekka commented 1 month ago

Same issue here.

SaveliiLukash commented 1 month ago

Very much reproducible and annoying.

As far as we know from #5907 our only hope is @Methuselah96 🙏

alfonsoluis commented 3 weeks ago

Same issue here, that is one nasty warning for such a nested aria definition