Skip to content

Instantly share code, notes, and snippets.

@ondrej
ondrej / example.js
Created June 29, 2018 17:16
Example for protocol.interceptStreamProtocol()
const r = require('request');
const zlib = require('zlib');
const text = require('text-encoding');
const stream = require('stream');
var interceptCallback = async (request: any, callback: any) => {
console.log(`intercepted ${request.method} ${request.url}`);
// TODO: support multiple upload data's
var options = {

Keybase proof

I hereby claim:

  • I am ondrej on github.
  • I am ondrej (https://keybase.io/ondrej) on keybase.
  • I have a public key whose fingerprint is C674 CE43 AC25 4D7F 57B2 B496 1996 C81A 32E2 FD5F

To claim this, I am signing this object:

@ondrej
ondrej / 0_reuse_code.js
Created October 27, 2015 18:03
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console