Skip to content

Instantly share code, notes, and snippets.

View wyqydsyq's full-sized avatar
🌏
Breaking the Internet

wyqydsyq wyqydsyq

🌏
Breaking the Internet
  • Brisbane, Australia
View GitHub Profile
@wyqydsyq
wyqydsyq / create-user.js
Last active July 22, 2016 07:01
Isomorphism
import {div, form, fieldset, legend, label, input, button, i, strong} from '@cycle/dom';
import {makeHTTPDriver} from '@cycle/http';
import isolate from '@cycle/isolate';
import xs from 'xstream';
import classes from 'dependencies/classes';
import styles from '../form/styles.less';
import LabelInput from 'components/label-input';
@wyqydsyq
wyqydsyq / createuser.js
Created July 25, 2016 03:45
HTTPDriver child component issues
import {div, form, fieldset, legend, label, input, button, i, strong} from '@cycle/dom';
import {makeHTTPDriver} from '@cycle/http';
import isolate from '@cycle/isolate';
import xs from 'xstream';
import classes from 'dependencies/classes';
import styles from '../form/styles.less';
import LabelInput from 'components/label-input';
@wyqydsyq
wyqydsyq / render.js
Last active July 26, 2016 01:29
Translate
// assuming your render component recieves a stream called selectedTargets$ that emits an object of the source/target languages you're translating
const vtree$ = sources.translate$.debug().map(translation =>
div('#registrationScreeenPage.panel.contentTop.active', [
div(translation('foo'))
]);
);
import Cycle from '@cycle/xstream-run'
import { makeDOMDriver } from '@cycle/dom'
import { timeDriver } from '@cycle/time'
const { rerunner, restartable } = require('cycle-restart')
import Main from './main'
const getMain = () => require('./main').default
const getDrivers = () => ({
@wyqydsyq
wyqydsyq / .tmux.conf
Last active June 19, 2017 04:32
My Tmux Config
run-shell "powerline-daemon -q"
source "/usr/lib/python3.6/site-packages/powerline/bindings/tmux/powerline.conf"
set-option -ga terminal-overrides ",xterm-256color:Tc"
set-option -g renumber-windows on
set-option -g history-limit 9001
set -g base-index 1
set -g mouse on
@wyqydsyq
wyqydsyq / test.tsx
Created March 17, 2017 05:02
Enzyme + MUI
import * as React from 'react'
import * as enzyme from 'enzyme'
import * as sinon from 'sinon'
import * as dom from 'jsdom'
import getMuiTheme from 'material-ui/styles/getMuiTheme'
import MyDialog from './MyDialog'
global['document'] = dom.jsdom('<html></html>')
@wyqydsyq
wyqydsyq / login.ts
Last active March 23, 2017 03:10
login.ts
import Auth0Lock from 'auth0-lock'
import { Observable } from 'rxjs'
import { push } from 'react-router-redux'
import { error as logError } from '../../util/logger'
import {
types as userTypes,
actions as userActions
} from '../actions/user'
@wyqydsyq
wyqydsyq / tump.txt
Created March 23, 2017 13:15
dota2 steam dump
Running Steam on opensuse tumbleweed 20170213 64-bit
STEAM_RUNTIME is enabled automatically
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
Installing breakpad exception handler for appid(steam)/version(1490127986)
@wyqydsyq
wyqydsyq / esnextbin.md
Last active May 2, 2017 05:23
esnextbin sketch
@wyqydsyq
wyqydsyq / hyper.js
Created May 22, 2017 04:56
hyper.js
// Future versions of Hyper may add additional config options,
// which will not automatically be merged into this file.
// See https://hyper.is#cfg for all currently supported options.
module.exports = {
config: {
// default font size in pixels for all tabs
fontSize: 16,
// font family with optional fallbacks