Show HN: A Javascript library to overcomplicate Five
jackdcrawford.github.io
jackdcrawford.github.io
Some people may rely on that functionality.
five.tooSlow = function() {
var returnIn = new Date(new Date().valueOf() + 555);
do {} while(new Date() < returnIn);
return five();
};
Finally a way to escape callback hell. I think somebody should write a jQuery.ajax plugin that calls the function repeatedly until a request is finished.You can make synchronous requests already though:
req = new XMLHttpRequest
req.open("some/url", "GET", false);
req.send()Until then I'm afraid this is just far too slow to consider using seriously in my web-scale project. This probably cant even handle 100M+ requests/second. Right now, its just me and grandma so I need 2 requests/sec, but this really doesn't seem scalable.
Sigh. I suppose I'll have to submit an issue and pull request.
Number.prototype.amIFive = function(){ return this.valueOf() == 5; }
5..amIFive();
`five-coffee` on npm.