Since Twitter doesn't have an edit button, it's a suitable host for JavaScript modules.
Source tweet: https://twitter.com/rauchg/status/712799807073419264
const leftPad = await requireFromTwitter('712799807073419264');
console.log(leftPad(1, 5)); // '00001'
console.log(leftPad(1234, 5)); // '01234'
console.log(leftPad(12345, 5)); // '12345'
# populate `twitter-config.json` with your API tokens
$ npm install
$ npm test
I took this a little more seriously, I think this might actually help out: https://www.npmjs.com/package/jhi
Create a file with a list of one-liners from anywhere (gist, github raw file, etc). It will pull them once into a directory and expose them via an
index.js
.