Ryan Grove rgrove

View yaypie.html
1 2 3 4 5 6 7 8 9 10
 
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>pie is good</title>
<style>
html { background: #fff; }
 
body {
View gist:4676369
1 2 3 4 5 6
var re = /a/g,
str ='foo bar biz quux';
 
console.log(re.exec(str)); // => ["a"]
re.lastIndex = 0;
console.log(re.exec(str)); // => ["a"] (would be null if lastIndex weren't reset)
View stache.js
1 2 3 4 5 6 7 8 9 10
(function () {
 
// -- Constructor --------------------------------------------------------------
function Stache(template) {
this.parsed = false;
this._template = template;
}
 
// -- Static Functions ---------------------------------------------------------
Stache.render = function (template, view, partials) {
View property-base.js
1 2 3 4 5 6 7 8 9 10
function Property() {}
 
Property.prototype = {
// -- Public Prototype Methods ---------------------------------------------
defineProperties: function (properties) {
return Property.defineProperties(this, properties);
},
 
defineProperty: function (name, descriptor) {
return Property.defineProperty(this, name, descriptor);
View gist:3658306
1 2 3 4 5 6 7 8 9 10
{
// enforcing options (true means potentially more warnings)
 
"bitwise": true, // true if bitwise operators should not be allowed
"curly": true, // true if curly braces should be required around blocks in loops and conditionals
"eqeqeq": true, // true if === should be required (for ALL equality comparisons)
"forin": false, // true if unfiltered 'for in' statements should be forbidden
"immed": true, // true if immediate function invocations must be wrapped in parens
"newcap": true, // true if Initial Caps must be used with constructor functions
"noarg": true, // true if arguments.caller and arguments.callee should be forbidden
View gist:3459993
1 2 3 4 5 6 7 8 9 10
function (Handlebars,depth0,helpers,partials,data) {
helpers = helpers || Handlebars.helpers;
var buffer = "", stack1, foundHelper, functionType="function", escapeExpression=this.escapeExpression, self=this, blockHelperMissing=helpers.blockHelperMissing;
 
function program1(depth0,data) {
var buffer = "", stack1, foundHelper;
buffer += "\n <li>";
foundHelper = helpers.item;
if (foundHelper) { stack1 = foundHelper.call(depth0, {hash:{}}); }
View gist:3459956
1 2 3 4 5 6 7 8 9 10
function (data) {
var $t='';
with(data){
$t+='<ul class="'+
Y.Escape.html( classNames.list )+
'">\
';
Y.Array.each(items, function (item) {
;$t+='\
<li>'+
View multi-yui.js
1 2 3 4 5 6 7 8 9
YUI.add('multi', function (Y) {
 
/**
Loads different versions of YUI in sandboxed iframes and makes them available
for use in the parent frame by exposing them as properties on a `Y.Multi`
instance.
 
This is primarily intended to be used for testing. You probably shouldn't use it
for anything real.
View node-scroll-info.js
1 2 3 4 5 6 7 8 9
/*!
Copyright (c) 2012 Ryan Grove. All rights reserved.
 
Redistribution and use of this software in source and binary forms, with or
without modification, are permitted provided that the following conditions are
met:
 
* Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.
View lazy-model-list.js
1 2 3 4 5 6 7 8 9 10
var AttrProto = Y.Attribute.prototype,
GlobalEnv = YUI.namespace('Env.Model'),
Lang = Y.Lang,
YArray = Y.Array,
 
EVT_ADD = 'add',
EVT_ERROR = 'error',
EVT_RESET = 'reset';
 
Y.LazyModelList = Y.Base.create('lazyModelList', Y.ModelList, [], {
Something went wrong with that request. Please try again.