Optimistic UI; a design and application/web-oriented method to improve the user experience. Its use and operation are slightly different, but its purpose is the same as many UX improvements; not to reflect delays to the user.
We don’t want to show the user lags most of the time. Even other similar examples; skeleton screens and animations. The main goal is to eliminate the feeling of freezing and not loading on the screen.