Created
October 29, 2012 04:18
-
-
Save swijw/3971488 to your computer and use it in GitHub Desktop.
Revisions
-
swijw revised this gist
Oct 29, 2012 . 1 changed file with 1 addition and 1 deletion.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -4,6 +4,6 @@ String.format = function(src) { } var args = Array.prototype.slice.call(arguments, 1); return src.replace(/\{(\d+)\}/g, function(m, i) { return args[i]; }); }; -
swijw revised this gist
Oct 29, 2012 . 1 changed file with 5 additions and 3 deletions.There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -1,7 +1,9 @@ String.format = function(src) { if (arguments.length) { return null; } var args = Array.prototype.slice.call(arguments, 1); return src.replace(/\{(\d+)\}/g, function(m, i) { return args[i]; }); }; -
swijw renamed this gist
Oct 29, 2012 . 1 changed file with 0 additions and 0 deletions.There are no files selected for viewing
File renamed without changes. -
swijw revised this gist
Oct 29, 2012 . No changes.There are no files selected for viewing
-
swijw created this gist
Oct 29, 2012 .There are no files selected for viewing
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 charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,7 @@ String.format = function(src){ if (arguments.length == 0) return null; var args = Array.prototype.slice.call(arguments, 1); return src.replace(/\{(\d+)\}/g, function(m, i){ return args[i]; }); };