Skip to content

Instantly share code, notes, and snippets.

@incompl
Last active January 4, 2021 18:54
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save incompl/1048678071ecfb280a5f to your computer and use it in GitHub Desktop.
Save incompl/1048678071ecfb280a5f to your computer and use it in GitHub Desktop.
The correct meta viewport tag to use for everything, please don't disable scaling thanks!
<meta name="viewport" content="width=device-width">

By default, phone browsers say "well crap, I'm, like, 320 pixels wide, and many websites were designed to be, like, 960 pixels wide, so I'm going to just scale down the content to 1/3 and show it that way."

By using the above meta tag, your website says "No no no, if your screen is tiny that's fine, just show this page like a 320 pixel wide browser and don't scale anything."

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment