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 trial

CSS

CSS media queries and Javascript

If im using screen size breakpoints, am i supposed to put javascript queries into the css media queries file or do i still put them in the main index.html file?

1 Answer

you cant put javascript in css!!! javascript only runs(gets executed) in a <script>tag inside a html file or inside a javascript file!

if you want to fire a particular js function for a particular screen size check this out http://www.sitepoint.com/javascript-media-queries/