Skip to content

Commit

Permalink
render is now an alias for pub in the browser side`
Browse files Browse the repository at this point in the history
  • Loading branch information
malgorithms committed Oct 11, 2012
1 parent 010c452 commit 2d3f17a
Show file tree
Hide file tree
Showing 6 changed files with 57 additions and 57 deletions.
2 changes: 1 addition & 1 deletion Cakefile
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ generateExpressTest = (cb) ->
</tr> </tr>
<script type="text/javascript"> <script type="text/javascript">
var gbid = function(x) {return document.getElementById(x); } var gbid = function(x) {return document.getElementById(x); }
var script_res = toffee.templates["/#{dir}/input.toffee"].pub(#{vars}); var script_res = toffee.templates["/#{dir}/input.toffee"].render(#{vars});
gbid("browser_#{rid}").innerHTML = script_res; gbid("browser_#{rid}").innerHTML = script_res;
if (gbid("browser_#{rid}").innerHTML == gbid("expected_#{rid}").innerHTML) { if (gbid("browser_#{rid}").innerHTML == gbid("expected_#{rid}").innerHTML) {
gbid("browser_#{rid}").style.backgroundColor="#dfe"; gbid("browser_#{rid}").style.backgroundColor="#dfe";
Expand Down
2 changes: 1 addition & 1 deletion lib/view.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Original file line Diff line number Diff line change
@@ -1,7 +1,7 @@
{ {
"name": "toffee", "name": "toffee",
"description": "A NodeJs, Express 3.x, Express 2.x, and browser-side templating language based on CoffeeScript with slicker tokens and syntax. Built with love at OkCupid.", "description": "A NodeJs, Express 3.x, Express 2.x, and browser-side templating language based on CoffeeScript with slicker tokens and syntax. Built with love at OkCupid.",
"version": "0.0.47", "version": "0.0.48",
"directories": { "directories": {
"lib": "./lib" "lib": "./lib"
}, },
Expand Down
2 changes: 1 addition & 1 deletion src/view.coffee
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -483,7 +483,7 @@ class view
#{if @browserMode then '' else getCommonHeaders(false)} #{if @browserMode then '' else getCommonHeaders(false)}
tmpl = toffee.templates["#{@bundlePath}"] = tmpl = toffee.templates["#{@bundlePath}"] =
bundlePath: "#{@bundlePath}" bundlePath: "#{@bundlePath}"
tmpl.pub = (__locals) -> tmpl.render = tmpl.pub = (__locals) ->
#{___}_to = (x) -> __locals.__toffee.out.push x #{___}_to = (x) -> __locals.__toffee.out.push x
#{___}_ln = (x) -> __locals.__toffee.lineno = x #{___}_ln = (x) -> __locals.__toffee.lineno = x
#{___}_ts = (x) -> __locals.__toffee.state = x #{___}_ts = (x) -> __locals.__toffee.state = x
Expand Down
Loading

0 comments on commit 2d3f17a

Please sign in to comment.