How do you change the blocks?



  • We need to change the blocks on the mob. Can bootstrap or skirt js?



  • The flexbox option, change the width of the browser window and see the elements change.

    .wrap {
      display: flex;
      flex-flow: column wrap;
    }
    .one {
      order: 2;
      background: green;
    }
    .two {
      order: 1;
      background: purple;
    }
    @media (min-width: 500px) {
      .one {
        order: 1;
      }
      .two {
        order: 2;
      }
    }
    <body>
      <div class="wrap">
        <div class="one">One</div>
        <div class="two">Two</div>
      </div>
    </body>


Log in to reply
 


Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2