I am experiencing an issue with SSR when initialItemCount is set.
Describe the bug
During SSR, the HTML correctly renders initialItemCount number of items. However, during the hydration process on the client-side, I noticed that these items get removed and then re-rendered. This seems to be due to the initial visibleRange being set to [0, 0].
To Reproduce
Steps to reproduce the behavior:
Set up a new React project with SSR enabled.
Create a component that uses the initialItemCount prop.
Render the component on the server side and send the HTML to the client.
On the client side, hydrate the app with ReactDOM.hydrate(<MyComponent />, document.getElementById('root')).
Expected behavior
The initial items rendered on the server should remain in the DOM without being removed and re-rendered during the hydration process.
I am experiencing an issue with SSR when
initialItemCount
is set.Describe the bug During SSR, the HTML correctly renders initialItemCount number of items. However, during the hydration process on the client-side, I noticed that these items get removed and then re-rendered. This seems to be due to the initial visibleRange being set to [0, 0].
To Reproduce Steps to reproduce the behavior:
ReactDOM.hydrate(<MyComponent />, document.getElementById('root'))
.Expected behavior The initial items rendered on the server should remain in the DOM without being removed and re-rendered during the hydration process.