Installing Brew
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Installing MSSQL Tools
brew tap microsoft/mssql-release https://github.com/Microsoft/homebrew-mssql-release
/** | |
* A script to auto add // @ts-ignore to lines with TypeScript compilation error | |
* This could be useful when you are upgrading your tsc version, or introduced new changes in tsconfig or just converting JS codebase to TS. | |
* Example usage: | |
* $ npx tsc > compilation-errors.log | |
* $ npx ts-node auto-ts-ignore.ts compilation-errors.log | |
*/ | |
import { readFile, writeFile } from 'fs/promises' |
Installing Brew
$ /usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
Installing MSSQL Tools
brew tap microsoft/mssql-release https://github.com/Microsoft/homebrew-mssql-release
React recently introduced an experimental profiler API. After discussing this API with several teams at Facebook, one common piece of feedback was that the performance information would be more useful if it could be associated with the events that caused the application to render (e.g. button click, XHR response). Tracing these events (or "interactions") would enable more powerful tooling to be built around the timing information, capable of answering questions like "What caused this really slow commit?" or "How long does it typically take for this interaction to update the DOM?".
With version 16.4.3, React added experimental support for this tracing by way of a new NPM package, scheduler. However the public API for this package is not yet finalized and will likely change with upcoming minor releases, so it should be used with caution.
If you haven’t worked with JavaScript in the last few years, these three points should give you enough knowledge to feel comfortable reading the React documentation:
let
and const
statements. For the purposes of the React documentation, you can consider them equivalent to var
.class
keyword to define JavaScript classes. There are two things worth remembering about them. Firstly, unlike with objects, you don't need to put commas between class method definitions. Secondly, unlike many other languages with classes, in JavaScript the value of this
in a method [depends on how it is called](https://developer.mozilla.org/en-US/docs/Web/Jav# Set the control character to Ctrl+Spacebar (instead of Ctrl+B) | |
set -g prefix C-space | |
unbind-key C-b | |
bind-key C-space send-prefix | |
# Set new panes to open in current directory | |
bind c new-window -c "#{pane_current_path}" | |
bind '"' split-window -c "#{pane_current_path}" | |
bind % split-window -h -c "#{pane_current_path}" |
<!-- Maker Link by @levelsio --> | |
<!-- MIT License --> | |
<style> | |
body { | |
background:#333; | |
} | |
.levelsio-by { | |
font-family:"Helvetica Neue",sans-serif; | |
right:0; |
.PHONY: help | |
# COLORS | |
GREEN := $(shell tput -Txterm setaf 2) | |
YELLOW := $(shell tput -Txterm setaf 3) | |
WHITE := $(shell tput -Txterm setaf 7) | |
RESET := $(shell tput -Txterm sgr0) | |
TARGET_MAX_CHAR_NUM=20 |
import { h, Component } from 'preact'; | |
/** Creates a new store, which is a tiny evented state container. | |
* @example | |
* let store = createStore(); | |
* store.subscribe( state => console.log(state) ); | |
* store.setState({ a: 'b' }); // logs { a: 'b' } | |
* store.setState({ c: 'd' }); // logs { c: 'd' } | |
*/ |
EMOJI CHEAT SHEET
Emoji emoticons listed on this page are supported on Campfire, GitHub, Basecamp, Redbooth, Trac, Flowdock, Sprint.ly, Kandan, Textbox.io, Kippt, Redmine, JabbR, Trello, Hall, plug.dj, Qiita, Zendesk, Ruby China, Grove, Idobata, NodeBB Forums, Slack, Streamup, OrganisedMinds, Hackpad, Cryptbin, Kato, Reportedly, Cheerful Ghost, IRCCloud, Dashcube, MyVideoGameList, Subrosa, Sococo, Quip, And Bang, Bonusly, Discourse, Ello, and Twemoji Awesome. However some of the emoji codes are not super easy to remember, so here is a little cheat sheet. ✈ Got flash enabled? Click the emoji code and it will be copied to your clipboard.
People
😄
#!/bin/bash | |
# Script to instruct the Mac how to route packets to the | |
# software defined network where containers created via boot2docker | |
# reside. This lets you casually directly to ports (ssh, http, etc. etc.) | |
# on those containers. | |
function ERROR(){ echo "ERROR: $*" ; } | |
function FAIL(){ echo "FAILING: $*" ; exit 1; } | |
if [[ 'running' != $(boot2docker status) ]] | |
then FAIL "boot2docker's VM not running" ; fi | |
IP_OF_DOCKER_HOST=$(boot2docker ip 2> /dev/null) |