View presentation here: http://bl.ocks.org/robcthegeek/raw/7d49beb1d7db07c2b74c/
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
In Third | |
In Second | |
In First | |
Press any key to continue... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* http://meyerweb.com/eric/thoughts/2011/01/03/reset-revisited/ | |
v2.0b1 | 201101 | |
NOTE: WORK IN PROGRESS | |
USE WITH CAUTION AND TEST WITH ABANDON */ | |
html, body, div, span, applet, object, iframe, | |
h1, h2, h3, h4, h5, h6, p, blockquote, pre, | |
a, abbr, acronym, address, big, cite, code, | |
del, dfn, em, img, ins, kbd, q, s, samp, | |
small, strike, strong, sub, sup, tt, var, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module URI | |
# For Times Where URI.escape should *ACTUALLY* Escape! | |
def self.great_escape(s) | |
URI.escape(s, Regexp.new("[^#{URI::PATTERN::UNRESERVED}]")) | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'bcrypt' | |
class User | |
include Mongoid::Document | |
include Mongoid::Timestamps | |
include BCrypt | |
attr_accessor :password, :password_confirmation | |
attr_protected :password_hash | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class String | |
# taken from: http://regexlib.com/REDetails.aspx?regexp_id=2558 - (escaped the forward-slashes as well) | |
def is_email? | |
self =~ /^((([!#$\%&'*+\-\/=?^_`{|}~\w])|([!#$\%&'*+\-\/=?^_`{|}~\w][!#$\%&'*+\-\/=?^_`{|}~\.\w]{0,}[!#$\%&'*+\-\/=?^_`{|}~\w]))[@]\w+([-.]\w+)*\.\w+([-.]\w+)*)$/ | |
end | |
def isnt_email? | |
!is_email? | |
end | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support/lsregister -kill -r -domain local -domain system -domain user |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.IO; | |
using System.Web.Mvc; | |
namespace Website.App.Extensions | |
{ | |
public static class ControllerExtensions | |
{ | |
public static string RenderPartialToString(this Controller controller, string partial, object model) | |
{ | |
controller.ViewData.Model = model; |
👏🏻 praise: With thanks to @pauloportella for the original Gist 🙏🏻
Make it easy to create Conventional Comments in GitHub by using saved replies'.
- Go to https://github.com/settings/replies
- Open Developer Tools (normally F12 or Ctrl/Cmd + Shift + I)
OlderNewer