/ypm-test-task

YPM React test task

Primary LanguageJavaScript

ypm-test-task

YPM React test task

Its just a optimized code. You can replace this to existing project file and can run it.

Used following techniques to optimize it.

  1. To reduce and optimize code, I have used map and reduce array methods instead of loop.
  2. For stop re-rendering, I have added hook - useEffect that will be run one time render only
  3. Same function used for first time render and when call the 'onPickHandler' props function of 'StudentsPicker' component