Skip to content

Instantly share code, notes, and snippets.

View akushnikov's full-sized avatar

Alexey Kushnikov akushnikov

  • Tula, Russian Federation
View GitHub Profile
@akushnikov
akushnikov / Singleton.js
Created March 30, 2016 10:35
ES6 singleton
class Singleton {
constructor() {
this.foo = 5;
}
static get Instance() {
if (this.instance == null || this.instance == undefined) {
this.instance = new Singleton();
}
return this.instance;
}
@akushnikov
akushnikov / inheritance.js
Created March 16, 2016 09:39
ES6 class system
class Human {
constructor(name) {
this.name = name;
}
introduce() {
console.log(`My name is ${this.name}`);
}
}
@akushnikov
akushnikov / Ext.ux.grid.plugin.CellDetalization.js
Created February 20, 2016 10:59
ExtJs grid cell detalization on ellipsis
Ext.define('Ext.ux.grid.plugin.CellDetalization', {
extend: 'Ext.AbstractPlugin',
alias: 'plugin.cell-detalization',
statics: {
ignoredXTypes: ['commandcolumn', 'componentcolumn', 'imagecommandcolumn', 'actioncolumn', 'header-action']
},
constructor: function () {
var me = this;
@akushnikov
akushnikov / SassMeister-input.scss
Created November 3, 2015 14:57
Generated by SassMeister.com.
// ----
// libsass (v3.2.5)
// ----
$buttons: (
('edit', -93px, -184px),
('remove', -93px, -207px),
('tune', -93px, -314px)
);