0

I wrote JS code with JQuery to change elements styles, position and wrap them. This was done after the page was loaded. I used dom ready function, but the elements have a jerky movement while applying changes. The first thing that came to mind was to create a full-size overlay div with an absolute position that would cover the whole page and I faded out that.

What are the best practices in these cases?

Mironline
  • 2,755
  • 7
  • 35
  • 61
  • Reveal section after it's ready, you can add page loader until like, reference https://stackoverflow.com/questions/1853662/how-to-show-page-loading-div-until-the-page-has-finished-loading – Girish Mar 02 '22 at 14:34
  • You might like to try at: https://ux.stackexchange.com/ – freedomn-m Mar 02 '22 at 14:50
  • 1
    As comment above: hide the section you're updating then `.show()` it when finished. A small dialog and/or animated loading icon centred on the page will show your users that it's doing something. However, there are advocates of letting the page draw in front of the user, again, so that they can see it doing something - as long as there's some way to know when it's finished. – freedomn-m Mar 02 '22 at 14:52

0 Answers0