Skip to content

Instantly share code, notes, and snippets.

protodave protodave

Block or report user

Report or block protodave

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
protodave / gist:40698bbdc50b1a70a20f
Last active Aug 29, 2015
Avoiding the FOUI (Flash of Unstyled Icon) in Iconic
View gist:40698bbdc50b1a70a20f
<!DOCTYPE html>
<html lang="en">
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Demo for Brian K.</title>
<script src="js/iconic.min.js"></script>
View gist:a71be73cd8e499c0b169
Template.main.rendered = function () {
$('body').scroll(function() {
var scrollTop = $(window).scrollTop();
// Do something now with this change here directly...
// :TODO:
// and/or save to Session so we can use it reactively
protodave / gist:ffddb1273dd75563b3d2
Created Dec 30, 2014
Meteor shared function pattern
View gist:ffddb1273dd75563b3d2
// Common, shared functions kept it the "app" namespace = || {}; = {
placeholder: function () {
return null;
protodave / gist:8d4d4700509ed36b825e
Last active Aug 29, 2015
Meteor app level Mongo `Distinct` emulation
View gist:8d4d4700509ed36b825e
var userTeams = Teams.find({
members: {
$in: [this.userId]
var userTeamMembers = _.chain(userTeams.fetch())
.map(function (team) {
return team.members;
You can’t perform that action at this time.