Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Media Queries for JS? Reply To: Media Queries for JS?

#169175
Anonymous
Inactive

You can put the code you want to remove in a separate js file, than append the file link when the browser width is above 980px, and then remove the file when its bellow 980px. I updated the pen.

Although i’m not even sure if that will work. I don’t know if removing a js file will also remove the js on the website in real-time. Also its likely theres an easier way of doing what your asking for.