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
(function(){ | |
"use strict"; | |
/** | |
* A factory for creating curry functions that | |
* are tied to the arrity of the function f. | |
*/ | |
function makeArrityBasedCurry(n) { | |
var curry = function(f){ | |
var args = [].slice.call(arguments, 1); |
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
(function(){ | |
"use strict"; | |
/** | |
* Creating a partial the hard way. | |
*/ | |
(function(){ | |
function add(x){ | |
return function(y){ |
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
/* | |
* Emulates classical inheritance and results in a | |
* prototype chain (nested prototypes) of baseclasses. | |
*/ | |
(function(){ | |
/* | |
* Extend childObj from parentObj and apply childPrototype to the childObj. | |
* @param {Objectl} childObj The child object. Required. | |
* @param {Objectl} parentObj The parent object. Required. |
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
/* Date Validation by Jeffrey Schwartz */ | |
(function(w){ | |
'use strict'; | |
var dv; | |
//define the project module's name space | |
w.ejr = w.ejr || {}; | |
//define this module's name space | |
dv = w.ejr.dateValidation = {}; | |
dv.isYearValid = function isYearValid(y){ | |
return typeof(y) === 'number'; |
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
'Preamble describe': | |
'prefix': 'describe' | |
'body': """ | |
describe('$1', function(){ | |
$2 | |
}); | |
""" | |
'Preamble it': | |
'prefix': 'it' | |
'body': """ |
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
/** | |
* Creates a new object that can be used as a protype for a ctor. | |
* @param api object The object whose own properties are to be copied to | |
* the new prototype object. | |
* @param ctr function The constructor function which will be set as the | |
* value of the new prototype's contructor property. | |
* @returns an object that can be uses as a protytpe. | |
*/ | |
function createPrototype(api, ctr){ | |
var ownProps = Object.getOwnPropertyNames(api), |
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
'.source.js': | |
'Preamble configure': | |
'prefix': 'configure' | |
'body': """ | |
configure({ | |
$1: $2, | |
}); | |
""" | |
'Preamble describe': | |
'prefix': 'describe' |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<!-- | |
Notes : | |
#1. change all link and script urls to match project | |
#2. you do not need any additional javascript to make nav-tabs work. just include | |
the bootstrap.js file as per the script tag at the bottom of the page. | |
--> |
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
"Currently Empty |
OlderNewer