Today I Learned
Tidbits of (hopefully) useful information on technologies and tools related to software development.

November 16, 2020 - HTTP


Response header to a preflight request (OPTIONS) that indicates which headers can be used when making the actual request.

# Example request
curl -vX OPTIONS \
  -H "Origin:" \
  -H "Access-Control-Request-Method: POST" \
  -H "Access-Control-Request-Headers: X-Some-Header" \

# Example response
# ...
< access-control-allow-origin:
< access-control-allow-methods: OPTIONS,POST
< access-control-allow-headers: X-Some-Header
# ...


Response header to an actual request that indicates which other response headers the client (ex: a browser) is allowed to access.

# Example request
curl -v -H "Origin:" \

# Example response
# ...
< access-control-allow-origin:
< access-control-expose-headers: X-Some-Header
# ...

November 09, 2020 - Fonts

Got a system font you want to convert into a web font?

cat font.ttf | npx ttf2woff2 >> font.woff2

Need to support older browsers?

npx ttf2woff font.ttf font.woff

Seeing command not found: npx?

You probably need to install Node.js.

Learnings sourced by everyone who has taught me, either directly or indirectly. Thanks!

Visit my main site for more, and sometimes longer, content.