Skip to content

Instantly share code, notes, and snippets.

@xdumaine
Created October 15, 2013 15:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xdumaine/6993196 to your computer and use it in GitHub Desktop.
Save xdumaine/6993196 to your computer and use it in GitHub Desktop.
Inject viewport with javascript
function injectViewportMetaTag() {
var meta = $(document.createElement('meta'));
meta.name = 'viewport';
meta.content = 'width=device-width, initial-scale=1';
$$('head')[0].insert(meta);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment