Skip to content

Instantly share code, notes, and snippets.

settings-sync
var persistantList = Ractive.extend({
partials: {item: "<li><a href='{{link}}'>{{title}}</a> <a on-click='remove(i)'>x</a></li>"},
data: function(){
return this.reference();
},
lifespan: 7,
key: 'programFavoritesList',
save: function(){
this.setCookie(this.key, JSON.stringify(this.get()), this.lifespan);
},
@nwpointer
nwpointer / test
Last active August 29, 2015 14:13
test
test.php
int[][] result;
float t;
float ease(float p) {
return 3*p*p - 2*p*p*p;
}
float ease(float p, float g) {
if (p < 0.5)
return 0.5 * pow(2*p, g);