node

vscode on osx can't find node

serve https locally

Create a certificate

openssl req -newkey rsa:2048 -new -nodes -x509 -days 3650 -keyout ~/git/key.pem -out ~/git/cert.pem

Current directory:

npx http-server -S --cors -C ~/git/cert.pem -K ~/git/key.pem -o --port 3001

A specific directory:

npx http-server my-directory -S --cors -C ~/git/cert.pem -K ~/git/key.pem -o --port 3001