How can you use media queries to target devices with retina displays specifically?
- @media (device-resolution: 2x)
- @media (min-device-pixel-ratio: 2)
- @media (min-resolution: 192dpi)
- @media (min-resolution: 2dppx)
To target devices with retina displays specifically, you can use the @media query and specify the min-device-pixel-ratio property. The value of 2 represents a typical retina display, where each CSS pixel corresponds to 2 physical device pixels. So, the correct option is @media (min-device-pixel-ratio: 2).
Loading...
Related Quiz
- Which CSS property allows you to control the speed curve of an animation?
- The CSS function ______ allows you to perform arithmetic calculations directly within your stylesheets.
- Which CSS pseudo-class would allow you to target only the last list item in an unordered list?
- You are tasked with creating a theme switcher that changes a set of color variables. How can SASS/SCSS functions assist in achieving this?
- In Flexbox, how would you align all items to the center of the container both vertically and horizontally?