Skip to content

Instantly share code, notes, and snippets.

View olebedev's full-sized avatar
🏄‍♂️
🌊 🌊 🌊

Oleg Lebedev olebedev

🏄‍♂️
🌊 🌊 🌊
View GitHub Profile
@seanhess
seanhess / omni-react.js
Created November 25, 2014 19:37
omniscient with react-router and immstruct
/**
* @jsx React.DOM
*/
window.React = require('react/addons');
var Immutable = require('immutable')
var component = require('omniscient')
var immstruct = require('immstruct')
var Router = require('react-router')
@benbjohnson
benbjohnson / lj.go
Created April 10, 2013 03:27
LuaJIT & Go Integration
package main
/*
#cgo LDFLAGS: -lluajit-5.1
#include <stdlib.h>
#include <luajit-2.0/lua.h>
#include <luajit-2.0/lualib.h>
#include <luajit-2.0/lauxlib.h>
int my_func() {
@ademuk
ademuk / wercker-dokku-deploy.yml
Created November 5, 2014 11:21
Wercker Dokku deploy
deploy:
steps:
- add-to-known_hosts:
hostname: $HOSTNAME
- add-ssh-key:
keyname: KEY
- script:
name: Push to dokku
code: |
git remote add dokku dokku@$HOSTNAME:$APP
@jmervine
jmervine / goinst.sh
Last active July 31, 2016 02:36
Installing GoLang - Ubuntu 12.04.3 LTS \n \l
#!/usr/bin/env bash
#
# Example usage:
#
# $ VERSION=1.3 sudo ./goinst.sh
if [ "$(id -u)" != "0" ]; then
echo "This script must be run as root" 1>&2
exit 1
fi
@skevy
skevy / gist:8a4ffc3cfdaf5fd68739
Last active February 4, 2017 04:59
Redux with reduced boilerplate

Note

I would recommend @acdlite's redux-actions over the methods suggested in this Gist.

The methods below can break hot-reloading and don't support Promise-based actions.

Even though 'redux-actions' still uses constants, I've come to terms with the fact that constants can be good, especially in bigger projects. You can reduce boilerplate in different places, as described in the redux docs here: http://gaearon.github.io/redux/docs/recipes/ReducingBoilerplate.html


@airportyh
airportyh / jsconf_slides_codes_and_notes.md
Last active June 19, 2017 20:51
JSConf 2014 Slides, Codes and Notes.

JSConf Slides, Codes and Notes

These are all the JSConf 2014 slides, codes, and notes I was able to cull together from twitter. Thanks to the speakers who posted them and thanks to @chantastic for posting his wonderful notes.

Modular frontend with NPM - Jake Verbaten (@Raynos)

@savelichalex
savelichalex / sector.js
Last active June 23, 2017 05:11
react native art sector
import {
ART,
Platform,
} from 'react-native';
const {
Surface,
Group,
Shape,
Path,
} = ART;
@einthusan
einthusan / go1.4arc65-ubuntu.sh
Last active July 10, 2018 23:43
Install Golang 1.4.1 on Ubuntu 14.04 AWS EC2
#!/bin/sh
# OPTIONAL FLAGS:
#
# -geoip true
# this will install maxmind geoip and auto update crontab file
#
# -cloudwatch true
# this will install aws cloud watch metrics and send them to aws dashboard
#
@gaearon
gaearon / ReduxMicroBoilerplate.js
Last active March 26, 2020 00:35
Super minimal React + Redux app
import React, { Component } from 'react';
import { createStore, combineReducers, applyMiddleware, bindActionCreators } from 'redux';
import { provide, connect } from 'react-redux';
import thunk from 'redux-thunk';
const AVAILABLE_SUBREDDITS = ['apple', 'pics'];
// ------------
// reducers
// ------------