Skip to content

Instantly share code, notes, and snippets.

hashtag = (function () {
// Twitter's official hashtag verifier.
// Ported from https://github.com/twitter/twitter-text-rb/blob/master/lib/twitter-text/regex.rb
// Creates a Unicode Regular Expression range
function regexRange (from, to) {
to = to || 0;
from = from.toString(16);
fromLen = (from.length > 4) ? from.length : 4;
@Warin
Warin / .gitignore
Created January 29, 2014 08:36
.gitignore boilerplate
# Compiled source #
###################
*.com
*.class
*.dll
*.exe
*.o
*.so
# Packages #
@Warin
Warin / base.css
Last active December 25, 2015 11:59
CSS: Custom Checkboxes on Webkit Demo: http://jsfiddle.net/FBjqm/
/**!
* Custom Checkbox for Webkit
* @author @Warin
*/
body {font-family:Arial,Verdana,sans-serif;}
@media screen and (-webkit-min-device-pixel-ratio:0) {
/*targets only webkit browsers*/
.fs+.fs {padding-top:5px;}
.fs>.field {position: relative;}
.fs_chk {-webkit-appearance:none;border:0;margin:0;display:block;float:left;}
@Warin
Warin / .jshintrc
Created March 11, 2013 10:49 — forked from haschek/.jshintrc
{
// --------------------------------------------------------------------
// JSHint Configuration, Strict Edition
// --------------------------------------------------------------------
//
// This is a options template for [JSHint][1], using [JSHint example][2]
// and [Ory Band's example][3] as basis and setting config values to
// be most strict:
//
// * set all enforcing options to true
@Warin
Warin / Bookmarklet: Firebug Lite
Created February 21, 2013 08:34
Content of the Firebug lite bookmarklet src:http://getfirebug.com/firebuglite
javascript:(function(F,i,r,e,b,u,g,L,I,T,E){if(F.getElementById(b))return;E=F[i+'NS']&&F.documentElement.namespaceURI;E=E?F[i+'NS'](E,'script'):F[i]('script');E[r]('id',b);E[r]('src',I+g+T);E[r](b,u);(F[e]('head')[0]||F[e]('body')[0]).appendChild(E);E=new%20Image;E[r]('src',I+L);})(document,'createElement','setAttribute','getElementsByTagName','FirebugLite','4','firebug-lite.js','releases/lite/latest/skin/xp/sprite.png','https://getfirebug.com/','#startOpened');
#!/bin/bash
## v1.0.6
## this script will gernerate css stats
### example output
# CSS STATS
# ----------
# Floats: 132