Created
August 13, 2010 01:16
-
-
Save mooz/522076 to your computer and use it in GitHub Desktop.
literal
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
HERE() | |
.input() | |
.the() | |
.string() | |
.and() | |
["this method chain"]() | |
.returns() | |
.accumulated() | |
.string(); |
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
function HERE() { | |
if (!(this instanceof HERE)) | |
return new HERE(); | |
this.strs = []; | |
} | |
HERE.prototype = { | |
__noSuchMethod__: | |
function (line) { | |
this.strs.push(line); | |
return this; | |
}, | |
toString: function () { | |
return this.strs ? this.strs.join("\n") : ""; | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment