Jump to content

How to show 2 items per row on mobile platform?

Recommended Posts

  • Replies 2
  • Views 1.8k
  • Created
  • Last Reply

Hey Edwardxu, this is a great use for flexbox. Try this:

@media(max-width:767px) {
  .products .list-grid{
    display:flex;
    flex-wrap:wrap;
  }
  .grid-item{
    flex: 0 1 50%;
  }
}

Let me know if that does it for you!

Hey there, my name is Will and I help Squarespace designers and developers with my plugins, tutorials, and my Code Curious Membership
  
I would be happy to answer any questions you have about Javascript, CSS, or the meaning of life  - I'm an expert in 2 of these. 

Youtube | Website

Link to comment
23 minutes ago, WillMyers said:

Hey Edwardxu, this is a great use for flexbox. Try this:


@media(max-width:767px) {
  .products .list-grid{
    display:flex;
    flex-wrap:wrap;
  }
  .grid-item{
    flex: 0 1 50%;
  }
}

Let me know if that does it for you!

Hi Will, It worked perfectly! Thank you so much!

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.