-
-
Save nathansmith/1441022 to your computer and use it in GitHub Desktop.
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8" /> | |
<meta http-equiv="x-ua-compatible" content="ie=edge, chrome=1" /> | |
<title>untitled</title> | |
<link rel="stylesheet" href="" /> | |
</head> | |
<body> | |
<script src=""></script> | |
</body> | |
</html> |
Yeah, if I'm writing HTML, I don't indent anything until the 2nd level of nestedness inside <body>
, since every site has <html>
, <head>
, and <body>
, I'm not usually visually scanning to find them. I tend to be focused on the "meat" of the page... the tags inside <body>
.
I take this minus the self-closing slashes, then add in HTML5 Boilerplate as needed. Thanks!
I just use Serve w/ my bootstrap. Deploy's to Heroku in minutes too.
@adamstac — Agreed. Serve is awesome.
But, it's overkill if I just want to have a valid HTML document to test something real quick. Chrome seems to not just like HTML snippets without at least an html
tag around 'em.
For instance, a few days ago, I was verifying a Formalize (http://formalize.me) bug reported in WebKit, so I put this in my minimal HTML template, tested it on the desktop, and then deleted it...
<!--
Other browsers only see size="2" and
higher, so they treat this as a single
select drop-down, but WebKit always
responds to size="..." attribute.
-->
<select>
<option>...</option>
<option>...</option>
</select>
<select size="0">
<option>...</option>
<option>...</option>
</select>
<select size="1">
<option>...</option>
<option>...</option>
</select>
In instances like that, setting up Serve would've been more effort than it's worth. So, that's why I keep a handy flat-file template at arm's length.
So lazy there aren't any indents either. Surprised you didn't post this in Haml.