Skip to content

Instantly share code, notes, and snippets.

一波不是一波 riskers

Block or report user

Report or block riskers

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
PCreations /
Last active Oct 29, 2019
Super Intuitive Interactive Diagrams to learn combining RxJS sequences by Max NgWizard K
wangcaipang / diff.js
Created May 26, 2017
react diff patch
View diff.js
export default function diff (parentNode, prevNodeMap, newNodeMap) {
let lastIndex = 0
let lastRightNode = null
let patch = []
let mountIndex = 0
for (let name in newNodeMap) {
if (newNodeMap.hasOwnProperty(name)) {
let newNode = newNodeMap[name]
let prevNode = prevNodeMap[name]
if (prevNode) {

stop all containers:

docker kill $(docker ps -q)

remove all containers

docker rm $(docker ps -a -q)

remove all docker images

subfuzion /
Last active Nov 15, 2019
curl POST examples

Common Options

-#, --progress-bar Make curl display a simple progress bar instead of the more informational standard meter.

-b, --cookie <name=data> Supply cookie with request. If no =, then specifies the cookie file to use (see -c).

-c, --cookie-jar <file name> File to save response cookies to.

View iOS 技能图谱.md


  • Swift
  • Objective-C
  • C++/C
  • JavaScript


  • Mac OSX
  • iOS
View 5 minute local Kubernetes Cluster on Mac
# Reference:
# install homebrew and cask
ruby -e "$(curl -fsSL"
# install virtualbox
brew cask install virtualbox
# install dockertoolbox
mauriciosoares / doubleclick.js
Created Oct 19, 2015
rxjs double click example
View doubleclick.js
let clickStream = Rx.Observable.fromEvent(document.getElementById('link'), 'click');
.map(list => list.length)
.filter(x => x === 2)
.subscribe(() => {
paulirish /
Last active Nov 14, 2019
What forces layout/reflow. The comprehensive list.

What forces layout / reflow

All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.


Box metrics
  • elem.offsetLeft, elem.offsetTop, elem.offsetWidth, elem.offsetHeight, elem.offsetParent
  • elem.clientLeft, elem.clientTop, elem.clientWidth, elem.clientHeight
  • elem.getClientRects(), elem.getBoundingClientRect()
vvgomes / foo.js
Last active Nov 2, 2019
Ramda vs Lodash
View foo.js
var _ = require("lodash");
var R = require("ramda");
var companies = [
{ name: "tw", since: 1993 },
{ name: "pucrs", since: 1930 },
{ name: "tw br", since: 2009 }
var r1 = _(companies).chain()
paulwellnerbou /
Created Jun 18, 2015
Getting git log between commits, branches and annotated tags with JGit
package de.wellnerbou.gitjira.jgit;
import org.eclipse.jgit.api.Git;
import org.eclipse.jgit.api.errors.GitAPIException;
import org.eclipse.jgit.lib.ObjectId;
import org.eclipse.jgit.lib.Ref;
import org.eclipse.jgit.lib.Repository;
import org.eclipse.jgit.revwalk.RevCommit;
You can’t perform that action at this time.