My website involves fetching data upon loading. I am working on implementing a preloader that will be displayed until the site fully loads and all initial requests are completed.
I've come across tutorials for preloaders that rely on setting a time interval, but I want my loader to genuinely wait for the page to finish loading.
Do you have any advice on how to achieve this?