Created
February 7, 2011 05:27
-
-
Save brito/814035 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
Requires jquery (not included) | |
<script src="jquery.js"></script> | |
Include gNius library | |
<script src="gNius.js"></script> | |
Your application data: | |
<script> | |
var articles = [ | |
{ title: "gNius Library launched!", icon: "gNius.png", summary: "Lorem ipsum..." }, | |
{ title: "Website looks almost decent!", icon: "website.png", summary: "Lorem ipsum..." }, | |
{ title: "Starter code initiated!", icon: "code.png", summary: "Lorem ipsum..." }, | |
]; | |
</script> | |
Markup: | |
<article> | |
<h2>$title</h2> | |
<img src="$icon" /> | |
<p>$summary</p> | |
</article> | |
Magic: | |
<script> | |
$('article').interpolate(articles); | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment