Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from cliffano/master
Replace sys.puts with console.log, sys module is removed from node core starting v0.7.0 .
- Loading branch information
Showing
14 changed files
with
17 additions
and
31 deletions.
There are no files selected for viewing
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
var jazz = require("../lib/jazz"); | ||
var sys = require("sys"); | ||
var fs = require("fs"); | ||
|
||
var data = fs.readFileSync(__dirname + "/foreach.jazz", "utf8"); | ||
var template = jazz.compile(data); | ||
template.eval({"people": ["Tom", "Danny", "Steve"]}, function(data) { sys.puts(data); }); | ||
template.eval({"people": ["Tom", "Danny", "Steve"]}, function(data) { console.log(data); }); |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,10 @@ | ||
var jazz = require("../lib/jazz"); | ||
var sys = require("sys"); | ||
var fs = require("fs"); | ||
|
||
var data = fs.readFileSync(__dirname + "/foreach_object.jazz", "utf8"); | ||
var template = jazz.compile(data); | ||
template.eval({"doc": { | ||
"title": "First", | ||
"content": "Some content" | ||
}}, function(data) { sys.puts(data); }); | ||
}}, function(data) { console.log(data); }); | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
var jazz = require("../lib/jazz"); | ||
var sys = require("sys"); | ||
var fs = require("fs"); | ||
|
||
var data = fs.readFileSync(__dirname + "/getattr.jazz", "utf8"); | ||
var template = jazz.compile(data); | ||
template.eval({"user": {"email_addresses": ["bob@foo.com", "bleh@blah.com"]}}, function(data) { sys.puts(data); }); | ||
template.eval({"user": {"email_addresses": ["bob@foo.com", "bleh@blah.com"]}}, function(data) { console.log(data); }); | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,13 @@ | ||
var jazz = require("../lib/jazz"); | ||
var sys = require("sys"); | ||
var fs = require("fs"); | ||
|
||
var data = fs.readFileSync(__dirname + "/html.jazz", "utf8"); | ||
var template = jazz.compile(data); | ||
|
||
template.eval({"username": ""}, function(data) { sys.puts(data); }); | ||
template.eval({"username": ""}, function(data) { console.log(data); }); | ||
|
||
template.eval({ | ||
"errors": ["Invalid username", "Please try again"], | ||
"username": "bert" | ||
}, function(data) { sys.puts(data); }); | ||
}, function(data) { console.log(data); }); | ||
|
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
var jazz = require("../lib/jazz"); | ||
var sys = require("sys"); | ||
var fs = require("fs"); | ||
|
||
var data = fs.readFileSync(__dirname + "/simple.jazz", "utf8"); | ||
var template = jazz.compile(data); | ||
template.eval({}, function(data) { sys.puts(data); }); | ||
template.eval({}, function(data) { console.log(data); }); | ||
|
||
|
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
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
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
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