Re:Responsive JavaScript
by criswell on Tuesday February 11, 2014 @07:05PM
(#7221563)
I really like Jeremy Keith's approach to "responsive javascript". He uses `:after` and updates the content property based on media queries. It keeps it nice and DRY. Here's a small demo: http://jsbin.com/meqon/2/edit?css,js,output
[ Parent
| on HN ]
Yes! Was surprised this wasn't there and was happy to see someone toss it in the comments :)
Edit: How he got there is a neat, quick read for anyone interested: http://adactio.com/journal/5429/