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 dis = 10 | |
, shiz = 'hurp' | |
, bananas = false | |
, bro = 100000 |
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
each user in @userLinks | |
if (usrId != user._id) | |
repAlert = new Alert({ # Create new alert | |
alertTime: new Date() | |
leadId: @_id | |
userId: user._id | |
creatorId: usrId | |
category: 'new_application' | |
comment: 'New application process for this lead!' | |
}) |
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> | |
<head> | |
<meta charset="utf-8"> | |
<style> | |
</style> | |
</head> | |
<body> | |
<h1>What?! HOLY SHMOKES</h1> | |
</body> | |
<script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/q.js/0.9.2/q.min.js"></script> |
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 Db = require('mongodb').Db, | |
MongoClient = require('mongodb').MongoClient, | |
Server = require('mongodb').Server, | |
ReplSetServers = require('mongodb').ReplSetServers, | |
ObjectID = require('mongodb').ObjectID, | |
Binary = require('mongodb').Binary, | |
GridStore = require('mongodb').GridStore, | |
Grid = require('mongodb').Grid, | |
Code = require('mongodb').Code, | |
BSON = require('mongodb').pure().BSON, |
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
$("#thedivtobehiddenifauserpressesonquestionbutton") |
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
CollectionOne.find( { 'search-term-here' : 'value' }, function(e, col1) { | |
if (e) return cb(e); | |
CollectionTwo.find( { 'your-search-here' : 'value' }, function(e, col2) { | |
if (e) return cb(e); | |
if (!results || !results.length) { | |
noPreviousResults(col1, cb); | |
} else { | |
previousResults(col1, col2, cb); | |
} |
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
Lead.find( {'$where' : "['fresh', 'new'].indexOf(this.status) > -1"} ) | |
// This runs JavaScript to figure out if the status wasn't "fresh" or "new" | |
Lead.find( {"status" : { "$nin" : [ "fresh", "new" ] } } ) | |
// Much more performant |
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 date = new Date(date); | |
if (!date.isDate()) console.error("When is a date not a date? When it's a NaN, of course."); |
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 $robots = $('meta[name="robots"]'); | |
$robots.each( function() { | |
var attribute = this.getAttribute('content'); | |
if ( attribute == "noindex,nofollow" || attribute == "nofollow,noindex" ) { | |
console.log( 'Page is%c noindex nofollowed', 'color: red; font-size: 2em;' ); | |
} | |
}); |
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 DATE_EXT = {}; | |
var extendMe; | |
DATE_EXT.getLabel = (function() { | |
return function() { | |
if( isNaN( this.getTime() ) ) return NaN; | |
return (this.getMonth() + 1) + '/' + this.getDate() + '/' + this.getFullYear().toString().substr(2,2); |
OlderNewer