Skip to content

Instantly share code, notes, and snippets.

View josh-yates's full-sized avatar
🤠

Josh Yates josh-yates

🤠
View GitHub Profile
.hidden-visually {
position: absolute;
width: 1px;
height: 1px;
margin: -1px;
padding: 0;
border: 0;
overflow: hidden;
clip: rect(0 0 0 0);
}
@bszwej
bszwej / echo.js
Last active October 20, 2025 12:56
Pure Node.js echo server, that logs all incoming http requests (method, path, headers, body).
const http = require('http');
const server = http.createServer();
server.on('request', (request, response) => {
let body = [];
request.on('data', (chunk) => {
body.push(chunk);
}).on('end', () => {
body = Buffer.concat(body).toString();