Load content dynamically & resize event
-
On complex layouts, heavy use of Media Queries affect performances since the mobile browser still loads all elements that has been hidden.
For what I understand now, to load the right layout/content at the right moment (screen-size/device) we should use javascript.
I’m working on a template that should turn into a mobile version when the screen width is less than 1080px.
To do this I was thinking to combine Modernizr.mq with a resize event listener but the I discovered http://wicky.nillia.ms/enquire.js which does pretty much the same out of the box.
Final question: How to serve parts of a wp-template through javascript ?
- The topic ‘Load content dynamically & resize event’ is closed to new replies.