Problem with preloader when clicking the Back button

Hello Andrey, I discovered that when I press the back button or swipe, the preloader still loads, how can I remove it when I press the back button.
tried using popup, didn’t help

@serhii @ihor @andrii help me

Please let me know which preloader you mean, the main website one which blocks the screen while the page is loaded or the form button preloader? If it’s the main one, you can consider disabling it in Appearance/Customize/Homepage.

@ihor or, I’m talking about the general preloader.
When you click on the back button, the preloader fires again, we want to remove the preloader when you click on the back button <button onclick="window.history.back()">Back</button>
Here is a simple example, I am an ordinary user who is looking for an advertisement from a mobile device, and I am not comfortable with the fact that the preloader works again when I click back.

Hi,

We checked this issue from our side, and it seems okay. Please try to test this on the demo version Themes | HivePress, and if everything works correctly, it is most likely due to custom code, third-party plugins, or cache. Also, it may be the specifics of your browser.

Andrey, we have carefully checked your test version of the ListingHive website, this also happens to you - only registered users.
Those who are not registered are doing great
How can we fix this?

window.addEventListener('popstate', function(event) {
    var preloader = document.querySelector('.site-loader ');
    if (preloader) {
        preloader.style.display = 'none';
    }
});

I added the JS snippet but it didn’t work

It’s not just about the preloader, the registered user’s page is reloaded when the browser’s back button is pressed, this has also been verified in tests on the website listinghive.hivepress.io.
I tried all the options to fix it for several days, but it didn’t work, the problem is with the hivepress plugin and it has nothing to do with the listinghive theme

Hi,

I’m sorry, we can’t repeat this issue locally. Please provide more details regarding this issue (e.g., your actions step by step with screenshots, etc.). This will help us to reproduce and resolve the issue faster. Also, provide information about the browser and device you are using.

You don’t need a video for this.
Just go to your site (favorite theme) and log in after hitting the browser’s back button and you’ll see what all the fuss is about. This is on all devices

Hi,

We have retested our demo version and everything is working correctly. Perhaps it is a specificity of your browser or its specific settings, so it does not work correctly for you. In order to test this in more detail, we need detailed steps. Otherwise, unfortunately, we cannot debug this further.