Skip to content

Instantly share code, notes, and snippets.

View sunnykgupta's full-sized avatar
👨‍💻
Building things!

Sunny sunnykgupta

👨‍💻
Building things!
View GitHub Profile
@eeshdarthvader
eeshdarthvader / reactivconf-2017.md
Created August 26, 2017 20:40
SERVICE WORKERS YOUR PERFECT MINIONS

This is a snapshot for ReactiveConf open call for lightning talks.

If you want to uncover the depth of service workers and how they are revolutionizing the page speed of web apps, please ⭐️ star this gist. #ReactiveConf

@gaearon
gaearon / slim-redux.js
Last active May 5, 2024 15:14
Redux without the sanity checks in a single file. Don't use this, use normal Redux. :-)
function mapValues(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
result[key] = fn(obj[key], key);
return result;
}, {});
}
function pick(obj, fn) {
return Object.keys(obj).reduce((result, key) => {
if (fn(obj[key])) {
@staltz
staltz / introrx.md
Last active May 10, 2024 12:08
The introduction to Reactive Programming you've been missing
@theprogrammerin
theprogrammerin / loadDev.js
Created March 13, 2014 06:46
Load Jquery & Underscore via console
function loadDev(){
var jq = document.createElement("script");
jq.setAttribute("src","http://code.jquery.com/jquery-2.1.0.js")
document.head.appendChild(jq);
var us = document.createElement("script");
us.setAttribute("src","http://underscorejs.org/underscore.js")
document.head.appendChild(us);
console.log("Loaded Jquery and Underscore")
}
loadDev()
@kevin-smets
kevin-smets / iterm2-solarized.md
Last active May 10, 2024 19:40
iTerm2 + Oh My Zsh + Solarized color scheme + Source Code Pro Powerline + Font Awesome + [Powerlevel10k] - (macOS)

Default

Default

Powerlevel10k

Powerlevel10k

@hellerbarde
hellerbarde / latency.markdown
Created May 31, 2012 13:16 — forked from jboner/latency.txt
Latency numbers every programmer should know

Latency numbers every programmer should know

L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns             
Compress 1K bytes with Zippy ............. 3,000 ns  =   3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns  =  20 µs
SSD random read ........................ 150,000 ns  = 150 µs

Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs