Created

Embed URL

HTTPS clone URL

SSH clone URL

You can clone with HTTPS or SSH.

Download Gist
View static file in node.js
1 2 3 4 5 6 7 8 9 10 11 12 13
fs.readFile(this.files[uri], "binary", function(err, content) {
if (err) {
res.sendHeader(404, {
});
} else {
res.sendHeader(200, {
"Content-Type": mime_type,
"Cache-Control": "public, max-age=300"
});
res.write(content, "binary");
}
res.end();
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.