Skip to content

Instantly share code, notes, and snippets.

View SanderSpies's full-sized avatar
🐫
wasm

Sander SanderSpies

🐫
wasm
View GitHub Profile

Parser

  • /src/parser/spider_monkey_ast.ml: The type definitions for the AST. Tries to stay very close to ESTree
  • /src/parser/lexer_flow.mll: The ocamllex lexer logic
  • /src/parser/parser_flow.ml: The recursive descent JS parser

Inference

  • /src/typing/type_inference_js.ml: Contains the "entry point" for inference (Function called infer_ast).
  • /src/typing/statement.ml: Most of the inference logic (runs through the AST and generates the initial constraints)
@reborg
reborg / clojure-irc-pdf-links
Last active July 16, 2017 15:18
PDF Links #Clojure IRC
@bensmithett
bensmithett / MyComponent.js
Created August 7, 2014 13:19
Trying out react-style
/**
* @jsx React.DOM
*/
"use strict";
var React = require("react/addons");
var ReactStyle = require("react-style");
var MyComponent = React.createClass({
@jordwalke
jordwalke / gist:6350319
Last active September 10, 2016 16:27
ReactJS: JavaScript just like you've always done it.
/**
* ReactJS: JavaScript like you've always done it.
*
* This example renders your top ten most followed friends/followers, `filter`ing
* only your favorites, and putting a star on all verified accounts.
*
* With ReactJS, any time your data changes, the UI is always brought up to date
* automatically. If friends length changes, or followCount - it always shows what
* `render` describes.
*/
@mkuklis
mkuklis / gist:5294248
Last active September 7, 2021 21:39
auto curry in JavaScript
function toArray(args) {
return [].slice.call(args);
}
function autocurry(fn) {
var len = fn.length;
var args = [];
return function next() {
args = args.concat(toArray(arguments));
return (args.length >= len) ?