Skip to content

Instantly share code, notes, and snippets.

Mikhail Davydov azproduction

Block or report user

Report or block azproduction

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
@azproduction
azproduction / b_.with.jsx
Last active Aug 29, 2015
BEM class name generator curring – b_.with
View b_.with.jsx
var B = require('b_');
var Array_of = function (any) {
return Array.prototype.slice.call(any);
};
B.with = function () {
var b = this,
curriedArgs = Array_of(arguments);
View scrollIntoView.js
/*!
* Copyright 2014 jQuery Foundation and other contributors
* Released under the MIT license.
*/
/**
* Better Element.scrollIntoView() implementation
*
* @see https://github.com/jquery/jquery-ui/blob/master/ui/menu.js#L409-L425
*
@azproduction
azproduction / cl.js
Last active Aug 29, 2015
WebStorm Live Templates
View cl.js
console.log($LINE$);
// LINE = lineNumber()
@azproduction
azproduction / _action.js
Last active Aug 29, 2015
Vision of Flux
View _action.js
// Action signature should be descriptive so IDE could use it.
var actionSet = createActions({
/**
* @param {object} data
* @param {string} data.name
* @param {string} data.value
*/
a: function actionMiddleware(data) {
// Case validate data
if (validate(data)) {
View index.js
// node --allow-natives-syntax index.js
var before, after, a;
before = %GetHeapUsage();
a = {};
after = %GetHeapUsage();
console.log(after - before);
@azproduction
azproduction / index.md
Created Apr 11, 2014
Deleted prototype element or function
View index.md
var encodeURIComponent, Array_push, Number_toString;
(function() {
    var iframe = document.createElement('iframe'), loaded = false;
    iframe.style.width = '1px';
    iframe.style.height = '1px';
    iframe.style.position = 'absolute';
    var onloadIframe = function() {
        if (!loaded && iframe.contentWindow) {
            loaded = true;
@azproduction
azproduction / index.md
Last active Feb 27, 2019
Спецификация 1CSS (статус: черновик спецификации)
View lmd.scope.js
/**
*
* @param {String} moduleName module name or path to file
*/
function require(moduleName) {}
/**
* Matches in-package modules
*
* @param {RegExp} regExp
@azproduction
azproduction / event.js
Last active Dec 16, 2015
yet another EventManager
View event.js
function EventManager () {
this._events = {};
}
EventManager.prototype = {
_event: function (type) {
var events = this._events[type];
if (!events) {
events = this._events[type] = {};
View anchor.html
<a href="javascript: void $.getScript('https://gist.github.com/azproduction/5092884/raw/2e2f414b04216770b05bb3d293e8efd741e91b3d/bookmarklet.js');">500px Tiles!</a>
You can’t perform that action at this time.