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
| 'use strict'; | |
| module.exports = function (grunt) { | |
| grunt.initConfig({ | |
| pkg: grunt.file.readJSON('package.json'), | |
| usebanner: { | |
| options: { | |
| banner: '/*!\n * <%= pkg.title || pkg.name %>\n * <%= pkg.description%>\n * Version <%= pkg.version%>\n * Compiled <%= grunt.template.today("dddd, mmmm dS, yyyy, h:MM:ss TT") %>\n */\n', | |
| }, |
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
| window.EventSubPubManager = window.EventSubPubManager || (function() { | |
| function EventSubPubManager() { | |
| this.__ = {} | |
| } | |
| EventSubPubManager.prototype.subscribe = function(topic, callback) { | |
| var callbacks = this.__[topic]; | |
| if (!callbacks) { | |
| callbacks = this.__[topic] = []; |
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
| Inline JavaScript comment: | |
| /*global jasmine, describe, xdescribe, it, xit, expect, beforeEach, afterEach, pending, spyOn*/ | |
| Configuration file: | |
| { | |
| "globals": { | |
| "jasmine": true, | |
| "describe": true, | |
| "xdescribe": true, |
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 initIE8Checkbox() { | |
| jQuery('body').find('input[type="checkbox"] + label, input[type="radio"] + label'). | |
| on('click', function (event) { | |
| var element = document.getElementById(event.target.getAttribute('for')); | |
| jQuery('body').find('input[name="' + element.name + '"]').removeClass('checked'); | |
| jQuery(element).toggleClass('checked'); | |
| }).each(function (index, element) { | |
| element = document.getElementById(element.getAttribute('for')); |
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
| { | |
| /* Enforcing options */ | |
| "bitwise": false, // This option prohibits the use of bitwise operators such as ^ (XOR), | (OR) and others. Bitwise operators are very rare in JavaScript programs and quite often & is simply a mistyped &&. | |
| "camelcase": true, // This option allows you to force all variable names to use either camelCase style or UPPER_CASE with underscores. | |
| "curly": true, // This option requires you to always put curly braces around blocks in loops and conditionals. | |
| "eqeqeq": true, // This options prohibits the use of == and != in favor of === and !==. | |
| "es3": false, // This option tells JSHint that your code needs to adhere to ECMAScript 3 specification. | |
| "forin": true, // This option requires all for in loops to filter object's items. | |
| "freeze": true, // This options prohibits overwriting prototypes of native objects such as Array, Date and so on. | |
| "immed": true, // This option prohibits the use of immediate function invocations without wrapping them in parentheses. |
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 dumpObject(object/*[, depth, name, objectHistory]*/) { | |
| var type = typeof object, | |
| isArray = object instanceof Array, | |
| isObject = type === 'object', | |
| isString = type === 'string', | |
| isFunction = type === 'function', | |
| isUndefined = type === 'undefined', | |
| isNull = object === null, | |
| prefix = ((isUndefined || isNull) ? '' : isString ? '"' : isArray ? '[' : isObject ? '{' : ''), | |
| posfix = ((isUndefined || isNull) ? '' : isString ? '"' : isArray ? ']' : isObject ? '}' : ''), |
NewerOlder