Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialSamuel Shackelford
1,213 Pointsdevice-height & device width deprecated?
According to
https://developer.mozilla.org/en-US/docs/Web/CSS/@media
the "device-width" and "device-height" features have been deprecated, are obsolete, and "are no longer guaranteed to work."
I'm assuming we'll be looking at other ways to display on phones and small devices, but perhaps not... Is this still a good way to do what we're trying to do?
Perhaps more importantly - is this a situation where someone with basic skill might do it this way, but someone who really knows what they're doing would use a completely different method?
1 Answer
axelh
10,077 PointsI must admit i never used "device-width" or "device-height". I just use the regular media queries (a shown below). And i never had any trouble. Or is there a specific reason you want to use this?
@media (min-width: 900px) {
***insert code***
}
}