What is the difference between Media Rule and Media Query?

Asked

Viewed 66 times

2

Sometimes I see one of these two terms being mentioned when it comes to responsiveness or adjusting content to variations of screen and device types.

Gazing this documentation in W3S it is said that:

Media query is a CSS technique introduced in CSS3. (translating: Media query is a CSS technique presented in CSS3).

And the Media Rule, Where does it come in? Reinforcing the question: both terms represent the same thing? If not, what is the difference between them?

1 answer

2


As Media Rule what you say are the @media which are rules. They are used to apply a style based on the result of one or more Media Query. That is, the style that is contained in the @media rule will be applied when the condition (Media Query) is true.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.