I hereby claim:
- I am deecewan on github.
- I am deecewan (https://keybase.io/deecewan) on keybase.
- I have a public key whose fingerprint is BE67 AC11 5662 B306 2C21 84FE E304 77EF 73F6 6487
To claim this, I am signing this object:
function wrapInProxy(target) { | |
return new Proxy(target, { | |
get: (target, name) => { | |
target.endpoint = target.endpoint || []; | |
const fn = (data) => dispatch => dispatch(makeRequest(name, target.endpoint.join('/'), data)); | |
fn.endpoint = [...target.endpoint, name]; | |
return wrapInProxy(fn); | |
} | |
}); | |
} |
import Express from 'express'; | |
let db = {}; | |
const app = new Express(); | |
app.post('/clear_data', (req, res) => { | |
db = {}; | |
res.sendStatus(200); | |
}); |
I hereby claim:
To claim this, I am signing this object:
/** | |
* This is a little, useless script that will highlight your Javadoc methods green when you click them. | |
* I made it because I kept looking at the wrong one when I was implementing it. | |
* | |
* Just copy and paste this into your browsers JS console. Changing tabs will break functionality. You'll have to redo it | |
*/ | |
[].forEach.call(document.querySelectorAll('h3'), function(tag){ | |
if (tag.parentNode.tagName == 'LI'){ | |
var theUl = tag.parentNode.querySelectorAll('ul.blockList, ul.blockListLast'); |
document.addEventListener('keydown', function(e){ | |
if (e.ctrlKey || e.metaKey){ | |
if (String.fromCharCode(e.which).toLowerCase() != 's') return; | |
e.preventDefault(); | |
console.log('Trying to save'); | |
} | |
}); |
var slack = require('./console-slack'); | |
slack.options = { | |
webhook : '<redacted>', | |
channel : '#testing-ground', | |
} | |
console.slack('Hello, World!', '#testing-ground', function(resp, status){ | |
console.slack("Response is: " + resp); | |
console.slack("Status is: " + status); |