Big list performance with React

后端 未结 9 896
甜味超标
甜味超标 2020-12-04 05:35

I am in the process of implementing a filterable list with React. The structure of the list is as shown in the image below.

PREMISE

9条回答
  •  执念已碎
    2020-12-04 06:10

    Try filter before loading into the React component and only show a reasonable amount of items in the component and load more on demand. Nobody can view that many items at one time.

    I don't think you are, but don't use indexes as keys.

    To find out the real reason why the development and production versions are different you could try profiling your code.

    Load your page, start recording, perform a change, stop recording and then check out the timings. See here for instructions for performance profiling in Chrome.

提交回复
热议问题