- Check if a page variable has been defined
-
Set variables in a page (page.html.haml) at the very biginning of the file:
--- variable: value variable2: value 2 ---
-
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
/** | |
* Display your window width - useful for responsive web design | |
* @author: Rutger Laurman | |
*/ | |
// Ready? | |
$(function(){ | |
// Create debug element | |
$("body").append("<div style='position:fixed;top:0;left:0;border:1px solid #999;background:#eee;' id='viewportwidth'></div>"); |