View react-url-query.d.ts
declare module 'react-url-query' { | |
import * as React from 'react'; | |
type Dictionary<T = string> = { | |
[key: string]: T; | |
}; | |
export const UrlQueryParamTypes: { | |
number: 'number'; | |
string: 'string'; |
View ControlDelegation.jsx
class Child extends React.Component { | |
static defaultProps = { | |
type: 'text', | |
onChange: () => {}, | |
value: '' | |
} | |
render() { | |
return <input {...this.props} />; | |
} | |
} |
View samplerest.js
var fs = require("fs") | |
var ssl_options = { | |
key: fs.readFileSync('privatekey.pem'), | |
cert: fs.readFileSync('certificate.pem') | |
}; | |
var port = process.env.PORT || 3000; | |
var express = require('express'); | |
var ejs = require('ejs'); | |
var passport = require('passport') |
View .atom
#sync-settings |
View blud.js
var Blud = Bro; | |
Blud.NANG = Bro.TOTALLY; | |
Blud.DRED = Bro.NOWAY; | |
var methods = { | |
// Blud(blud1).manz('sket') | |
manz: Bro.prototype.doYouEven, | |
// Blud(blud1).dash('puff') | |
dash: Bro.prototype.iCanHaz, |
View injector.js
/** | |
* @constructor | |
*/ | |
function Injector() { | |
/** | |
* @type {!Object.<string, function(Injector=): !Object>} | |
*/ | |
this.factories = {}; |
View checked.js
/** | |
* Radio button and checkbox replacement | |
* Author: Jakub Korzeniowski | |
* Agency: Softhis | |
* http://www.softhis.com | |
*/ | |
(function($) { | |
$.fn.checked = function() { |
View clamp.js
/** | |
* Clamps a number. Based on Zevan's idea: http://actionsnippet.com/?p=475 | |
* params: val, min, max | |
* Author: Jakub Korzeniowski | |
* Agency: Softhis | |
* http://www.softhis.com | |
*/ | |
(function(){Math.clamp=function(a,b,c){return Math.max(b,Math.min(c,a));}})(); |
View container.css
.streched { | |
height: auto; | |
position: absolute; | |
top: 0; | |
bottom: 0; | |
left: 0; | |
right: 0; | |
} |
View color.js
'#' + (function(h){return new Array(7-h.length).join("0")+h})((Math.random()*0x1000000<<0).toString(16)) |
NewerOlder