['0', '1','2','2','1','0'].map(parseInt)
A: 0, 1, 2, 2, 1, 0
B: 0, 0, 0, 0, 0, 0
C: 0, NaN, NaN, 2, 1, 0
D: 0, NaN, NaN, NaN, NaN, NaN
E: NaN, NaN, NaN, NaN, NaN, NaN
One of the main reasons is, to make sure that we always get another set of 👀 on all the code that is going into production. And secondly, it's to improve our collective knowledge 🧠.
When you're reviewing a PR:
- ❓ If you do not understand something, ask why, it was done this way.
- 💕 If you like something, point out that you liked it.
- 🐠 If you see something fishy, voice your concern and suggest ways how we can make it better.
- 🏰 Don’t just think about the raw lines of code being added/removed. Think about the impact of this change in the project in general.
- 🔍 And, be thorough, dry run the code in your head, see if it makes sense, you can catch bugs before they even get merged (P.S. the only way to get better at this is to practice it a lot! So go ahead and start today :man-lifting-weights:).
- 🤝 No one is here to judge, that is not our job. Don't be shy to share your work and comment on other people's work. The goal is to impro
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var PARENT_LABEL = 'GH'; | |
var GITHUB_NOTIFICATION_EMAIL = '[email protected]'; | |
var ISSUE_STRING = "\"description\": \"View this Issue on GitHub\""; | |
var PR_STRING = "\"description\": \"View this Pull Request on GitHub\""; | |
function addGitHubLabels() { | |
// Let's do some set up here | |
createLabelIfNeeded(PARENT_LABEL); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# You can craete a token from https://github.com/settings/tokens and give the | |
# "repo" persmission to the token | |
AUTH_TOKEN=$1 | |
OWNERREPO=$2 | |
if [[ "$#" -ne 2 ]]; then | |
echo "Usage: $0 AUTH_TOKEN OWNER/REPO\n" | |
exit 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env node | |
var e = ['🐒','🦍','🦧','🐶','🐕','🐩','🐺','🦊','🦝','🐱','🐈','🐈⬛','🦁','🐯','🐅','🐆','🐴','🐎','🦄','🦓','🦌','🦬','🐮','🐂','🐃','🐄','🐷','🐖','🐗','🐏','🐑','🐐','🐪','🐫','🦙','🦒','🐘','🦣','🦏','🦛','🐭','🐁','🐀','🐹','🐰','🐇','🐿️','🦫','🦔','🦇','🐻','🐻❄️','🐨','🐼','🦥','🦦','🦨','🦘','🦡','🦃','🐔','🐓','🐣','🐤','🐥','🐦','🐧','🕊️','🦅','🦆','🦢','🦉','🦤','🦩','🦚','🦜','🐸','🐊','🐢','🦎','🐍','🐲','🐉','🦕','🦖','🐳','🐋','🐬','🦭','🐟','🐠','🐡','🦈','🐙','🐚','🪸','🐌','🦋','🐛','🐜','🐝','🪲','🐞','🦗','🪳','🕷️','🦂','🦟','🪰','🪱','🦀','🦞','🦐','🦑'] | |
console.log(`Good morning everyone ${e[Math.floor(Math.random()*e.length)]}`) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
router.on('router:navigation:complete', e => { | |
console.log('🐞 router:navigation:complete', e); | |
}); | |
router.on('router:navigation:cancelled', e => { | |
console.log('🐞 router:navigation:cancelled', e); | |
}); | |
router.on('router:navigation:processing', e => { | |
console.log('🐞 router:navigation:processing', e); | |
}); | |
router.on('router:route:activating', e => { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/local/bin/gnuplot --persist | |
# If you want to save on disk png … or set "export GNUTERM=x11" for X11 screen window | |
set terminal png | |
set output "result.plo.png" | |
set title "Benchmark1" | |
set size 1,0.7 | |
set xlabel 'requests' | |
set ylabel 'ms' | |
# if you want to use autoscale use "set autoscale xy" | |
set xrange [0:100] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { concat, defer, empty, of } from "rxjs"; | |
import { flatMap, reduce, scan, take } from "rxjs/operators"; | |
const fetchPage = (pageNumber = 0) => | |
new Promise(r => { | |
setTimeout(() => { | |
// console.log("fetching page ", pageNumber); | |
if (pageNumber >= 5) { | |
return r({ results: "done" }); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const sleep = ms => new Promise(r => setTimeout(r, ms)); | |
const numbersFromGenerator = fromI => { | |
let i = fromI; | |
return { | |
[Symbol.asyncIterator]: async function*() { | |
while (true) { | |
await sleep(500); | |
yield i++; |
NewerOlder