Skip to content

Commit

Permalink
link to the hightlighted source code in all examples
Browse files Browse the repository at this point in the history
  • Loading branch information
dodo committed May 18, 2012
1 parent fea29fb commit 62500af
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 11 deletions.
3 changes: 2 additions & 1 deletion example/animation.coffee
@@ -1,3 +1,4 @@
srcdirurl = "https://github.com/dodo/node-dynamictemplate/blob/master/example"
{ Template, jqueryify } = window.dynamictemplate
{ random, floor, pow } = Math
running = yes
Expand Down Expand Up @@ -45,7 +46,7 @@ animation = jqueryify new Template schema:5, ->
@$div class:'controls', ->
button this, "start", ""
button this, "stop", ""
@$a href:"./animation.coffee", "Source Code"
@$a href:"#{srcdirurl}/animation.coffee", "Source Code"
@$div class:'canvas', ->
createSquare this
createSquare this
Expand Down
8 changes: 5 additions & 3 deletions example/backbone.html
Expand Up @@ -17,9 +17,11 @@
<!-- <script src="./list.js"></script> -->
</head>
<body>
<p>
Hit the buttons! <a href="./backbone.coffee">Source Code</a>
</p>
<p>
Hit the buttons! <a href="https://github.com/dodo/node-dynamictemplate/blob/master/example/backbone.coffee">
Source Code
</a>
</p>
<!-- this is the space where the template will be -->
</body>
</html>
3 changes: 2 additions & 1 deletion example/circles.coffee
@@ -1,3 +1,4 @@
srcdirurl = "https://github.com/dodo/node-dynamictemplate/blob/master/example"
{ Template, domify } = window.dynamictemplate
{ random, floor, min } = Math
running = yes
Expand Down Expand Up @@ -35,7 +36,7 @@ svg = domify new Template schema:5, ->
@$div class:'controls', ->
button this, "start", ""
button this, "stop", ""
@$a href:"./circles.coffee", "Source Code"
@$a href:"#{srcdirurl}/circles.coffee", "Source Code"
@$div class:'canvas', ->
@add new Template schema:'svg', ->
@$svg {
Expand Down
11 changes: 7 additions & 4 deletions example/list.html
Expand Up @@ -4,7 +4,8 @@
<title>dynamictemplate test</title>
<link rel="stylesheet" href="base.css">
<link rel="stylesheet" href="list.css">
<script src="http://code.jquery.com/jquery-1.7.js"></script>
<!-- <script src="http://code.jquery.com/jquery-1.7.js"></script> -->
<script src="./jquery-1.6.2.js"></script>
<script src="http://coffeescript.org/extras/coffee-script.js"></script>
<script src="http://documentcloud.github.com/underscore/underscore.js"></script>
<script src="../dt-list.browser.js"></script>
Expand All @@ -14,9 +15,11 @@
<script type="text/coffeescript" src="./list.coffee"></script>
</head>
<body>
<p>
Hit the buttons! <a href="./list.coffee">Source Code</a>
</p>
<p>
Hit the buttons! <a href="https://github.com/dodo/node-dynamictemplate/blob/master/example/list.coffee">
Source Code
</a>
</p>
<!-- this is the space where the template will be -->
</body>
</html>
3 changes: 2 additions & 1 deletion example/quadtree.coffee
@@ -1,3 +1,4 @@
srcdirurl = "https://github.com/dodo/node-dynamictemplate/blob/master/example"
{ Template, domify } = window.dynamictemplate
{ random, floor, min, max } = Math
running = yes
Expand Down Expand Up @@ -169,7 +170,7 @@ svg = domify new Template schema:5, ->
@$div class:'controls', ->
button this, "start", ""
button this, "stop", ""
@$a href:"./quadtree.coffee", "Source Code"
@$a href:"#{srcdirurl}/quadtree.coffee", "Source Code"
@$div class:'canvas', ->
@add new Template schema:'svg', ->
@$svg {
Expand Down
3 changes: 2 additions & 1 deletion example/svg.coffee
@@ -1,3 +1,4 @@
srcdirurl = "https://github.com/dodo/node-dynamictemplate/blob/master/example"
{ Template, domify } = window.dynamictemplate
{ abs } = Math
running = yes
Expand All @@ -16,7 +17,7 @@ svg = domify new Template schema:5, ->
@$div class:'controls', ->
button this, "start", ""
button this, "stop", ""
@$a href:"./svg.coffee", "Source Code"
@$a href:"#{srcdirurl}/svg.coffee", "Source Code"
@$div class:'canvas', ->
@add new Template schema:'svg', ->
@$svg {
Expand Down

0 comments on commit 62500af

Please sign in to comment.