Created
February 12, 2010 22:16
-
-
Save defunkt/303039 to your computer and use it in GitHub Desktop.
Haml + Mustache
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
#content | |
.left.column | |
%h2 Welcome to our site! | |
.right.column | |
#users | |
{{#users}} | |
%p {{user}} | |
{{/users}} |
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
--- | |
users: | |
- { user: chris } | |
- { user: bob } | |
- { user: jones } | |
--- |
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
$ cat example.yml example.haml.mustache | mustache | haml -s | |
<div id='content'> | |
<div class='left column'> | |
<h2>Welcome to our site!</h2> | |
</div> | |
<div class='right column'> | |
<div id='users'> | |
<p>chris</p> | |
<p>bob</p> | |
<p>jones</p> | |
</div> | |
</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
thanks for this inspiration. see https://github.com/mikesmullin/mustache_rails3