README
XHRProxy.js
XMLHttpRequest Proxy for Browser and WebWorkers.
Document
How to use
Browser
<script src="lib/XHRProxy.js"></script>
<script>
XHRProxy.get("./index.html", function(error, responseText, xhr) {
console.log(responseText);
});
</script>
WebWorkers
importScripts("lib/XHRProxy.js");
XHRProxy.get("./index.html", function(error, responseText, xhr) {
console.log(responseText);
});
Node.js
Use NodeProxy.js.
var NodeProxy = require("uupaa.nodeproxy.js");
NodeProxy.get("./index.html", function(error, responseText, xhr) {
console.log(responseText);
});