Closed ghost closed 8 years ago
You could create a simple helper function, which wraps your listener object and adds/removes an element from the DOM on match/unmatch. Something like this: https://jsfiddle.net/e1agyhtn/
Been pullig my hair over this and will learn tons from your fiddle. Thank you so much!!
Hi Nick, trying to display the current media query on the page. reference
Perhaps you could help out or point in the right direction?
Just learning all this and during development it would help me super lots to have a simple div with the current media query range displayed, e.g. appended to the body.