Performance: JpaRepository interface
MEDIUM IMPACT
This affects backend data fetching speed and how quickly data is available to render on the frontend.
Page<User> users = userRepository.findAll(PageRequest.of(0, 20)); // fetches only first 20 users
List<User> users = userRepository.findAll(); // fetches all users without filtering or pagination| Pattern | DOM Operations | Reflows | Paint Cost | Verdict |
|---|---|---|---|---|
| Fetching all data without limits | N/A (server-side) | N/A | N/A | [X] Bad |
| Fetching paged data with JpaRepository | N/A (server-side) | N/A | N/A | [OK] Good |