Skip to content

Instantly share code, notes, and snippets.

View Josh68's full-sized avatar

Josh Schneider Josh68

View GitHub Profile
@Josh68
Josh68 / dabblet.css
Last active December 14, 2022 21:22 — forked from LeaVerou/dabblet.css
Flexible multiline definition list
/**
* Flexible multiline definition list
*/
dl { width: 200px; display: grid; grid-template-columns: 1fr 80%; gap: .5em .25em; }
dt { counter-increment: css-counter 1; font-weight: bold; white-space: nowrap; }
dt::before { content: counter(css-counter)". "; font-weight: normal; }
dt::after { content: ":"; }
@Josh68
Josh68 / static_server.js
Created October 19, 2015 18:03 — forked from ryanflorence/static_server.js
Node.JS static file web server. Put it in your path to fire up servers in any directory, takes an optional port argument.
var http = require("http"),
url = require("url"),
path = require("path"),
fs = require("fs")
port = process.argv[2] || 8888;
http.createServer(function(request, response) {
var uri = url.parse(request.url).pathname
, filename = path.join(process.cwd(), uri);