Skip to content

Instantly share code, notes, and snippets.

@chunpu
Last active August 29, 2015 13:57
Show Gist options
  • Save chunpu/9478222 to your computer and use it in GitHub Desktop.
Save chunpu/9478222 to your computer and use it in GitHub Desktop.
A standard html layout I think, ( to be improved
<!-- default tab (easy to paste) -->
<!-- html5 is here to replace aria role, no role -->
<!-- to validator (http://validator.w3.org/nu/) -->
<!doctype html>
<!-- no html lang (avoid chrome translation) -->
<html>
<head>
<!-- default utf-8 -->
<meta charset="utf-8">
<!-- title -->
<title>Template</title>
<!-- for 360 and later more double core browsers -->
<meta name="renderer" content="webkit">
<!-- keywords -->
<meta name="keywords" content="content1 content2">
<!-- description -->
<meta name="description" content="description">
<!-- viewport -->
<meta name="viewport" content="width=device-width">
<!-- your style.css -->
<!-- fuck ie (https://github.com/aFarkas/html5shiv) -->
<!--[if lt IE 9]>
<script src="./html5shiv.js"></script>
<![endif]-->
</head>
<body>
<header>
<nav>
<!-- site nav -->
<ul>
<li></li>
<li></li>
...
</ul>
</nav>
<!-- logo | banner -->
</header>
<main class="inner">
<!-- always for id="content", or grid element -->
<!-- main is unique in the body -->
<!-- inner or container class is sth like `margin: 0 auto; width: 1000px; (max-width...)` -->
</main>
<footer>
<!-- Copyright © | address | contact | license -->
</footer>
<!-- scripts -->
<!-- jquery goes first -->
<!-- your app js -->
<!-- google analytics -->
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment