Skip to content

Instantly share code, notes, and snippets.

View mizhon's full-sized avatar
🫥

mister.z mizhon

🫥
  • China
View GitHub Profile
@mizhon
mizhon / .eslintrc.js
Created May 25, 2020 08:22 — forked from adrianhall/.eslintrc.js
A sample .eslintrc file
var OFF = 0, WARN = 1, ERROR = 2;
module.exports = exports = {
"env": {
"es6": true
},
"ecmaFeatures": {
// env=es6 doesn't include modules, which we are using
"modules": true
@mizhon
mizhon / introrx.md
Created May 20, 2020 08:18 — forked from staltz/introrx.md
The introduction to Reactive Programming you've been missing
@mizhon
mizhon / analytics.js
Created May 20, 2020 03:27 — forked from zmmbreeze/analytics.js
GA的源码 analytics.js
(function() {
/**
* 记录方法使用情况的类
* @param {Array.<boolean>} umMap 初始的使用情况
*/
var UsageManager = function(umMap) {
this.umMap = umMap || [];
};
/**
* 记录新的使用情况
@mizhon
mizhon / less_loop_expression.less
Last active February 1, 2019 16:00
Less loop expression
/* Define two variables as the loop limits */
@from: 1;
@to: 12;
/* Create a Parametric mixin and add a guard operation */
.loop(@index) when(@index =< @to) {
&:nth-child(@{index}) {
animation-delay: (@index - 1) /12s; // calc with the unit
transform: rotate(30deg * (@index - 6)) translateY(-150%);
}