Skip to content

Instantly share code, notes, and snippets.

View kayhadrin's full-sized avatar

David kayhadrin

  • AU-US in betweener
View GitHub Profile
/*\
|*|
|*| :: cookies.js ::
|*|
|*| A complete cookies reader/writer framework with full unicode support.
|*|
|*| https://developer.mozilla.org/en-US/docs/DOM/document.cookie
|*|
|*| This framework is released under the GNU Public License, version 3 or later.
|*| http://www.gnu.org/licenses/gpl-3.0-standalone.html
/**
* unformat method: reverse formatting
* @author Markus J Doetsch markus.doetsch@rocket-internet.de
*/
window.unformat = function (formatting, val) {
"use strict";
// only work with (formatted) strings
if (typeof val !== 'string') {
@blakehaswell
blakehaswell / Gruntfile.js
Created January 21, 2013 10:05
Gruntfile for running automated tests using Jasmine.
module.exports = function (grunt) {
grunt.initConfig({
connect: {
jasmine: {
options: {
hostname: 'localhost',
port: 9001
}
}
@rcorreia
rcorreia / drag_and_drop_helper.js
Last active August 11, 2023 06:41
drag_and_drop_helper.js
(function( $ ) {
$.fn.simulateDragDrop = function(options) {
return this.each(function() {
new $.simulateDragDrop(this, options);
});
};
$.simulateDragDrop = function(elem, options) {
this.options = options;
this.simulateEvent(elem, options);
};