DEV Community

avcat
avcat

Posted on

@media (768px < width <= 1024px) - 92% support (Media Queries Range Syntax)

That's it! I think we can finally start using more convenient syntax for media queries.

/* Newer syntax */
@media (768px < width <= 1024px) {
  body {
    background-color: lightblue;
  }
}

/* Older syntax */
@media (min-width: 769px) and (max-width: 1024px) {
  body {
    background-color: lightblue;
  }
}
Enter fullscreen mode Exit fullscreen mode

Source: caniuse.

Top comments (0)