Skip to content

Instantly share code, notes, and snippets.

View alexeagle's full-sized avatar
🌿
Making a better Bazel

Alex Eagle alexeagle

🌿
Making a better Bazel
View GitHub Profile
<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="initial-scale=1.0, user-scalable=no" />
<style type="text/css">
html { height: 100% }
body { height: 100%; margin: 0px; padding: 0px }
#map_canvas { height: 100% }
</style>
<script type="text/javascript"
diff --git a/src/compiler/types.ts b/src/compiler/types.ts
index a18cc84..4467b91 100644
--- a/src/compiler/types.ts
+++ b/src/compiler/types.ts
@@ -357,6 +357,10 @@ module ts {
FailedAndReported = 3
}
+ export interface NodeVisitor<R, P> {
+ visitSourceFile(node: SourceFile, p: P): R;
cd TypeScript
git reset --hard 62b15de666fbce283b97f1f99c2f799d04a8e0b5 # HEAD from master
npm install reflect-metadata
rm -rf built && jake
node built/local/tsc.js test.ts -t es6 --emitDecoratorMetadata
npm install -g babel
babel test.js > app_bin.js
# load test.html in browser
@alexeagle
alexeagle / angular2.d.ts
Last active August 29, 2015 14:22
angular2.d.ts
// Type definitions for Angular v2.0.0-alpha.26
// Project: http://angular.io/
// Definitions by: angular team <https://github.com/angular/>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
// ***********************************************************
// This file is generated by the Angular build process.
// Please do not create manual edits or send pull requests
// modifying this file.
// ***********************************************************
@alexeagle
alexeagle / gulpfile.js
Created July 15, 2015 18:58
check semicolons
'use strict';
var autoprefixer = require('gulp-autoprefixer');
var clangFormat = require('clang-format');
var del = require('del');
var exec = require('child_process').exec;
var fork = require('child_process').fork;
var gulp = require('gulp');
var gulpFormat = require('gulp-clang-format');
var gulpPlugins = require('gulp-load-plugins')();
// Type definitions for Angular v2.0.0-local_sha.bc2a5ee
// Project: http://angular.io/
// Definitions by: angular team <https://github.com/angular/>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
// ***********************************************************
// This file is generated by the Angular build process.
// Please do not create manual edits or send pull requests
// modifying this file.
// ***********************************************************
import {__compiler_private__ as _c} from '@angular/compiler';
export type SelectorMatcher = typeof _c.SelectorMatcher;
export var SelectorMatcher: typeof _c.SelectorMatcher = _c.SelectorMatcher;
export type CssSelector = typeof _c.CssSelector;
export var CssSelector: typeof _c.CssSelector = _c.CssSelector;
import {__platform_browser_private__ as _} from '@angular/platform-browser';
@alexeagle
alexeagle / titleUrlMarkdownClip.js
Last active August 3, 2023 19:13 — forked from bradleybossard/titleUrlMarkdownClip.js
Bookmarklet to copy current page title and url in Markdown format to clipboard, like [title](url) - Usual for posting links to resources in README.md files
javascript:(function() {
function copyToClipboard(text) {
if (window.clipboardData && window.clipboardData.setData) {
/*IE specific code path to prevent textarea being shown while dialog is visible.*/
return clipboardData.setData("Text", text);
} else if (document.queryCommandSupported && document.queryCommandSupported("copy")) {
var textarea = document.createElement("textarea");
textarea.textContent = text;
BasedOnStyle: Google
Language: JavaScript
ColumnLimit: 100
let formatted = true;
// clang-format off
formatted = long_method_name(`long string literal template ${with_interpolation}`);
// clang-format on
let formatted = true;