Skip to content

Instantly share code, notes, and snippets.

John-David Dalton jdalton

Block or report user

Report or block jdalton

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
jkrems /
Last active Jan 25, 2020
History of ES modules
ceejbot /
Last active Jul 17, 2019
npm's proposal for supporting ES modules in node

ESM modules in node: npm edition

The proposal you’re about to read is not just a proposal. We have a working implementation of almost everything we discussed here. We encourage you to checkout and build our branch: our fork, with the relevant branch selected. Building and using the implementation will give you a better understanding of what using it as a developer is like.

Our implementation ended up differing from the proposal on some minor points. As our last action item before making a PR, we’re writing documentation on what we did. While I loathe pointing to tests in lieu of documentation, they will be helpful until we complete writing docs: the unit tests.

This repo also contains a bundled version of npm that has a new command, asset. You can read the documentation for and goals of that comma

RReverser / acorn-top-level.js
Created Mar 14, 2017
Acorn: top-level parsing experiment
View acorn-top-level.js
// See for example
acorn.plugins.top_level = function (instance) {
// Could skip other things as well, but this
// is where the most time can be saved
instance.parseBlock = function () {
var node = this.startNode();
var length = this.context.length;
do {;
chicoxyzzy /
Last active Aug 13, 2019
Installing Node Nightlies via nvm

You can install Node Nightlies/RCs via nvm using NVM_NODEJS_ORG_MIRROR environment variable.

Install latest Node RC


Install latest Node.js Nightly

View karmakarmakarmakarmakarmakamillion.js
var browserslist = require('browserslist');
var request = require('sync-request');
var res = request('GET', '');
function lookup(requestedBrowsers, cb) {
var result = {};
var sauce = JSON.parse(res.getBody().toString())
michaelficarra / append-template-tag.js
Created May 30, 2016
chainable template tag for joining a bunch of strings over many lines
View append-template-tag.js
function append(separator) {
return typeof separator === "string" ? appender(separator, "") : appender("", "").apply(this, arguments);
function appender(separator, s) {
return function tag(literalParts, ...computedParts) {
s += literalParts[0];
for (let i = 1; i < literalParts.length; ++i) {
s += computedParts[i - 1] + literalParts[i];
View eshost-output.txt
> eshost host --list
│ name │ type │ path │ args │
│ chakra │ ch │ C:\Users\brterlso\projects\runify\hosts\ch.exe │ │
│ node │ node │ c:\Program Files\nodejs\node.exe │ │
│ spidermonkey │ jsshell │ C:\Users\brterlso\projects\runify\hosts\js.exe │ │
bcoe /
Last active Nov 28, 2019

npm Users By Downloads (

npm users sorted by the monthly downloads of their modules, for the range May 6, 2018 until Jun 6, 2018.

Metrics are calculated using top-npm-users.

# User Downloads
deathbearbrown /
Last active Apr 27, 2017
Please be accessible, my dudes.

If you have images and you are showing them on the web using an <img> tag, you must ALWAYS include alt text.

If you are writing markdown, you have no excuse not to add alt text.

![Alt text right here buddy](src)

Doing this is lazy. You're better than that.

View tonicify-lodash.js
(function () {
var textarea;
function createTextArea() {
if (textarea) {
return textarea;
textarea = document.createElement('textarea'); = 'absolute'; = '-9999px'; = (window.pageYOffset || document.documentElement.scrollTop) + 'px';
You can’t perform that action at this time.