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(){ | |
var ctx = document.getElementById('draw-canvas').getContext('2d'), | |
penX = [], | |
penY = [], | |
saveStates = [], | |
drawOn = false, | |
trackingInitialized = false, | |
canvasWidth, canvasHeight; | |
ctx.strokeStyle = '#000'; |
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
var module = (function(){ | |
var privateNum = 10; | |
function privateFn(){ | |
return privateNum * 2; | |
} | |
function publicFn(){ | |
return privateFn(); | |
} |
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
App.Views.Base = Backbone.View.extend({ | |
templateName: null, | |
render: function(){ | |
var data; | |
if(this.templateName !== null){ | |
if(this.model !== null){ | |
data = this.model.toJSON() |
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
{ | |
"name": "modulejs", | |
"version": "0.0.1", | |
"description": "A new module", | |
"license": "MIT", | |
"private": true, | |
"authors": [ | |
"mparke" | |
], | |
"devDependencies": { |
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(App, Array) { | |
'use strict'; | |
var slice = Array.prototype.slice; | |
function Events () { | |
var events = {}; | |
function on (eventName, callback, context) { | |
if (!events[eventName]) { | |
events[eventName] = []; |
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 ($, Namespace) { | |
'use strict'; | |
var slice = Array.prototype.slice; | |
function widget (widgetName, constructor) { | |
var namespace = 'fifty.' + widgetName; | |
return function (options) { | |
var $el = $(this), | |
args = slice.call(arguments), |
NewerOlder