Hi. I’m trying to use the mediaquerylist object in a program and would like to not be hard-coding values in window.matchmedia(); Has anyone ever tried to do something like this?
window.matchMedia("(max-width:" + somefunction + “px )”);
Mine doesn’t seem to be working and I’m not sure if it’s because matchMedia only accepts actual CSS arguments.
Thanks in advance!