Created
September 25, 2014 11:12
-
-
Save SteveBenner/5df58e30de5165a44822 to your computer and use it in GitHub Desktop.
Slim template - Lean version of HTML5 Boilerplate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ruby: | |
google_analytics_key = 'UA-XXXXXXXX-X' # your key may have more or less characters | |
page_title = '' | |
page_description = '' | |
doctype html | |
== conditional_html_tags_for_ie_versions 7..8, lang: 'en' | |
head | |
meta charset="utf-8" | |
meta http-equiv="X-UA-Compatible" content="IE=edge; chrome=1" | |
title = page_title | |
meta name="description" content=page_description | |
meta name="viewport" content="width=device-width, initial-scale=1" | |
/ load stylesheets here | |
/ load preliminary scripts here | |
body | |
/[if lt IE 7] | |
p.browsehappy | |
| You are using an <strong>outdated</strong> browser. Please | |
| <a href="http://browsehappy.com/">Upgrade your browser to improve your experience!</a> | |
header | |
main | |
footer | |
/ load main scripts here | |
/ Google Analytics tracking code (updated 2014-10-23) | |
javascript: | |
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ | |
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), | |
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) | |
})(window,document,'script','//www.google-analytics.com/analytics.js','ga'); | |
ga('create','#{google_analytics_key}','auto');ga('send','pageview'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<!--[if lt IE 7]<html class="no-js lt-ie9 lt-ie8 lt-ie7" lang="en"><![endif]--> | |
<!--[if IE 7]<html class="no-js lt-ie9 lt-ie8" lang="en"><![endif]--> | |
<!--[if IE 8]<html class="no-js lt-ie9" lang="en"><![endif]--> | |
<!--[if gt IE 8]<!--><html class="no-js" lang="en"><!--<![endif]--> | |
<head> | |
<meta charset="utf-8" /> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge; chrome=1" /> | |
<title></title> | |
<meta name="description" content="" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1" /> | |
</head> | |
<body> | |
<!--[if lt IE 7]> | |
<p class="browsehappy"> | |
You are using an <strong>outdated</strong> browser. Please<a href="http://browsehappy.com/">Upgrade your browser to improve your experience!</a> | |
</p> | |
<![endif]--> | |
<header></header> | |
<main></main> | |
<footer></footer> | |
<script type="text/javascript"> | |
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ | |
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), | |
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) | |
})(window,document,'script','//www.google-analytics.com/analytics.js','ga'); | |
ga('create','UA-XXXXXXXX-X','auto');ga('send','pageview'); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The
conditional_html_tags_for_ie_versions
helper can be found in this gist.More information about this template can be found here.