Performance: @Email and @Pattern
LOW IMPACT
These annotations affect form validation speed and user input responsiveness during server-side validation.
@Email private String email;
@Pattern(regexp = ".*@[a-z]+\\.[a-z]{2,3}")
private String email;| Pattern | DOM Operations | Reflows | Paint Cost | Verdict |
|---|---|---|---|---|
| @Email annotation | 0 | 0 | 0 | [OK] Good |
| Simple @Pattern regex | 0 | 0 | 0 | [!] OK |
| Complex @Pattern regex | 0 | 0 | 0 | [X] Bad |