title: How to make sure preloader covers entire height and there is no loading page element visible?
body: <p>How to make sure preloader covers entire height and there is no loading page element visible?   </p>
  
  <blockquote>
    <p>When i run this code the content inside  is visible
    when i scroll down. How do i make sure the preloader bg covers the
    entire page ?</p>
  </blockquote>
  
  <p>html:</p>
  
  <pre><code>&lt;div class="pre-outer"&gt;
      &lt;div class="preloader"&gt;
  
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;section class="home-section-background padding-bottom-0"&gt;
  &lt;/section&gt;
  </code></pre>
  
  <p>css:</p>
  
  <pre><code>/*loader styles */
      .pre-outer
      {
        background: rgba(1,1,1,1);
        width: 100%;
        z-index: 999;
                height: 100%!important;
      }
      .preloader {
         display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        overflow-y: hidden;
        -webkit-box-pack: center;
            -ms-flex-pack: center;
                justify-content: center;
        -webkit-box-align: center;
            -ms-flex-align: center;
                align-items: center;
  
        overflow: hidden;
        background: rgba(1,1,1,1);
        width: 100%;
        position: absolute;
                z-index: 999;
                height: 100%!important;
        -webkit-animation: glow 8s both;
                animation: glow 8s both;
  
      }
  </code></pre>
  
  <p>javascript code for loader:</p>
  
  <pre><code>&lt;script&gt;
  $(window).load(function () {
  
  
              $('.pre-outer').delay(8000).fadeOut('slow');//loader div
  
          });
  &lt;/script&gt;
  </code></pre>