This file contains hidden or 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
{ | |
"directory": "components" | |
} |
This file contains hidden or 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
this.collection.comparator = 'id'; | |
this.collection.sort(); | |
this.collection.trigger('reset'); |
This file contains hidden or 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
# 0 is too far from ` ;) | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
#set -g default-terminal screen-256color | |
set -g status-keys vi | |
set -g history-limit 10000 |
This file contains hidden or 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
function evenRound(num, decimalPlaces) { | |
var d = decimalPlaces || 0; | |
var m = Math.pow(10, d); | |
var n = +(d ? num * m : num).toFixed(8); // Avoid rounding errors | |
var i = Math.floor(n), f = n - i; | |
var e = 1e-8; // Allow for rounding errors in f | |
var r = (f > 0.5 - e && f < 0.5 + e) ? | |
((i % 2 == 0) ? i : i + 1) : Math.round(n); | |
return d ? r / m : r; | |
} |
This file contains hidden or 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
var braintreeKey = isLocalhost() ? app.config.SANDBOX_PUBLIC_KEY : app.config.PRODUCTION_PUBLIC_KEY | |
var braintree = Braintree.create(braintreeKey); | |
// ... | |
params.cc_expiration_date = braintree.encrypt(params.cc_expiration_date) | |
params.cc_number = braintree.encrypt(params.cc_number) | |
params.cc_cvv = braintree.encrypt(params.cc_cvv) |
This file contains hidden or 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
$ccNumberInput.payment('formatCardNumber') | |
$securityCodeInput.payment('formatCardCVC') | |
var valid = $.payment.validateCardNumber(cardNumber) | |
var cardType = $.payment.cardType(cardNumber) | |
var isCvcValid = $.payment.validateCardCVC(cvv, cardType) |
This file contains hidden or 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
&:after { z-index: -1; position: absolute; content: ""; bottom: 15px; right: 5px; width: 50%; height: 8px; | |
max-width: 300px; background: hsl(0, 0%, 47%); box-shadow: 0 10px 10px hsl(0, 0%, 47%); | |
-webkit-transform: rotate(3deg); | |
} |
This file contains hidden or 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
/*jshint browser: true, onevar: false, strict: false, eqeqeq: false */ | |
/*global IDBKeyRange, define, exports, module */ | |
// index.js | |
// Provides easy interaction with indexedDB | |
// --- | |
// Part of the Riggr SPA framework <https://github.com/Fluidbyte/Riggr> and released | |
// under the MIT license. This notice must remain intact. | |
(function (root, factory) { | |
if (typeof define === 'function' && define.amd) { | |
define([], factory); |
This file contains hidden or 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
Show hidden characters
{ | |
"asi": true, | |
"bitwise": true, | |
"boss": false, | |
"browser": false, | |
"camelcase": true, | |
"couch": false, | |
"curly": true, | |
"debug": false, | |
"devel": false, |
This file contains hidden or 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
/** | |
* Created by frank on 1/8/14. | |
* http://stackoverflow.com/questions/1184624/convert-form-data-to-js-object-with-jquery | |
*/ | |
(function ($) { | |
$.fn.serializeObject = function (options) { | |
options = options || {} | |
var defaults = { | |
includeUnderscore: false, | |
exclude: [] |