Skip to content

Instantly share code, notes, and snippets.

View iofjuupasli's full-sized avatar

Valery iofjuupasli

  • fugo.ai
  • Warsaw, Poland
  • 10:56 (UTC +02:00)
View GitHub Profile
return (
<li className={classNames({
completed: this.props.todo.completed,
editing: this.props.editing
})}>
<div className="view">
<input
className="toggle"
type="checkbox"
checked={this.props.todo.completed}
@iofjuupasli
iofjuupasli / worse-better.md
Created August 23, 2015 13:51
Чем хуже, тем лучше

Чем хуже, тем лучше: JS

Почему я полюбил динамическую типизацию?

Я очень часто встречал мнение, что для очень больших проектов безусловно нужны языки со статической типизацией. Что 1 млн строк кода можно написать только на Java.

Однако я заметил, что на JS я должен писать свой код настолько простым, чтобы всегда было его очень легко понимать и использовать. И писать его как можно более модульно и лаконично.

@iofjuupasli
iofjuupasli / async-in-js.md
Last active August 29, 2015 14:26
async graphs in js

Comparison of several ways of working with complex async graphs in js

  A     E
 /|\    |
B | C   F
 \|/
  D
iofjuupasli@iofjuupasli:~/projects/timeraven$ ssh root@188.166.101.74
The authenticity of host '188.166.101.74 (188.166.101.74)' can't be established.
ECDSA key fingerprint is 84:4f:ff:cf:95:a8:5a:d4:72:90:56:c9:6a:37:b6:b5.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '188.166.101.74' (ECDSA) to the list of known hosts.
Welcome to Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-43-generic x86_64)
* Documentation: https://help.ubuntu.com/
System information as of Fri Apr 24 02:49:47 EDT 2015
function add(a) {return function(b){return a + b}}
function nEq(a) {return function(b){return a !== b}}
function eq(a) {return function(b){return a === b}}
function always(val) {return function(){return val}}
function id(a){return a}
function getPropertyValue(prop){
var val;
prop.take(1).onValue(function(_val){val = _val});
return val;
@iofjuupasli
iofjuupasli / features.md
Last active August 29, 2015 14:16
Atom features wanted
  • Tree: goto
  • Tree: lint subtree
  • Rename file shortcut
echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc
. ~/.bashrc
mkdir ~/local
mkdir ~/node-latest-install
cd ~/node-latest-install
curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1
./configure --prefix=/home/$USER/local
make install
curl -O -L https://www.npmjs.org/install.sh | sh
@iofjuupasli
iofjuupasli / double-comma.sublime-macro
Created January 16, 2015 13:00
sublime text double comma\semicolon to end of string
[
{
"args":
{
"to": "eol"
},
"command": "move_to"
},
{
"args":
/*jslint nomen: true, vars: true*/
/*global define*/
define(['jquery', 'lodash'], function ($, _) {
'use strict';
var FallbackCrud = (function () {
function Class() {
this.cruds = arguments;
}
_.forEach(['create', 'read', 'update', 'del'], function (method) {