Created
June 14, 2015 08:08
-
-
Save brandoncordell/992502b52bcc51089ca9 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
/heres a simple div with an id | |
#my-div This is my cool div | |
results: <div id="my-div">This is my cool div</div> | |
/heres a simple div with a class | |
.my-div This is my cool div | |
results: <div class="my-div">This is my cool div</div> | |
/heres a nested example | |
.my-div | |
This is my div with a strong element inside | |
%strong.my-strong-element This will be bold | |
results: | |
<div class="my-div"> | |
This is my cool div | |
<strong class="my-strong-element">This will be bold</strong> | |
</div> | |
/ an example with ruby code | |
/ setup: @page_title is view variable holding the string "Page One" | |
%h1.page-title= @page_title | |
results: <h1 class="page-title">Page One</h1> | |
/ here it is with concatenation | |
%h1.page-title "My cool #{@page_title" | |
results: <h1 class="page-title">My cool Page One</h1> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment