Skip to content

Instantly share code, notes, and snippets.

View imerkle's full-sized avatar

imerkle imerkle

View GitHub Profile
@imerkle
imerkle / stuns
Created December 23, 2016 19:04 — forked from yetithefoot/stuns
STUN+TURN servers list
{url:'stun:stun01.sipphone.com'},
{url:'stun:stun.ekiga.net'},
{url:'stun:stun.fwdnet.net'},
{url:'stun:stun.ideasip.com'},
{url:'stun:stun.iptel.org'},
{url:'stun:stun.rixtelecom.se'},
{url:'stun:stun.schlund.de'},
{url:'stun:stun.l.google.com:19302'},
{url:'stun:stun1.l.google.com:19302'},
{url:'stun:stun2.l.google.com:19302'},

Keybase proof

I hereby claim:

  • I am dsslimshaddy on github.
  • I am dsslimshaddy (https://keybase.io/dsslimshaddy) on keybase.
  • I have a public key whose fingerprint is 119A 4CC7 D742 E417 559A F97F 8A8D F7BA F5ED 5266

To claim this, I am signing this object:

@imerkle
imerkle / noinline.js
Last active July 7, 2017 20:00
SO react no-inline checkpoint file
import React from 'react';
import PropTypes from 'prop-types';
import { injectStyle } from 'styletron-utils';
function removeInline(reactEl,styletron){
let newChildrens;
if(reactEl.props.children){
if(reactEl.props.children instanceof Array){
@imerkle
imerkle / eslintrc
Created July 8, 2017 21:18
eslint rc
{
"parser": "babel-eslint",
"extends": ["airbnb"]
"plugins": ["babel","react","flowtype"]
}
@imerkle
imerkle / YARN.md
Last active July 10, 2017 15:55
yarn package mofos

DEV without css

yarn add babel-cli babel-loader babel-preset-env babel-preset-react babel-preset-stage-1 babel-plugin-transform-class-properties babel-plugin-transform-react-remove-prop-types

@imerkle
imerkle / .babelrc-example
Last active July 10, 2017 15:55
babel rc react js
{
"presets": ["stage-1", "react"],
"plugins": ["transform-decorators-legacy","transform-class-properties"],
"env": {
"development": {
"sourceMaps": "both",
"plugins": [
"flow-react-proptypes",
"transform-flow-strip-types"
]
const isArray = (a) => {
return (!!a) && (a.constructor === Array);
};
const isObject = (a) => {
return (!!a) && (a.constructor === Object);
};
const gunToObj = (obj,getKey,putKey) => {
getKey = (typeof(getKey) === 'undefined') ? '_title' : getKey;
putKey = (typeof(putKey) === 'undefined') ? 'title' : putKey;
@imerkle
imerkle / anottest.vtt
Last active July 15, 2017 19:30
anootation test for video playert
WEBVTT FILE
00:00:04.000 --> 00:00:10.000
4 to 10 seconds im show#xywh=0$^0$^167$^94
00:00:10.004 --> 00:00:16.008
10 to 16 seconds im show#xywh=167$^0$^167$^94
00:00:15.004 --> 00:00:21.000
@imerkle
imerkle / annotest.json
Last active July 16, 2017 22:39
json of anootiation
{
"res": [
{
"end": 10000,
"start": 4000,
"text": "4 to 10 seconds im show",
"style": {
"height": 200
}
},
@imerkle
imerkle / colorfromstring.txt
Created July 26, 2017 16:57
genarate color from string
const getHashCode = str => {
let hash = 0;
for (let i = 0; i < str.length; i++) {
hash = str.charCodeAt(i) + ((hash << 5) - hash);
}
return hash;
};
const getHSL = (number, saturation, lightness) => {
var shortened = Math.abs(number % 360);