Skip to content

Instantly share code, notes, and snippets.

View dixon's full-sized avatar

Jarrod Dixon dixon

View GitHub Profile

Keybase proof

I hereby claim:

  • I am dixon on github.
  • I am jarrod_dixon (https://keybase.io/jarrod_dixon) on keybase.
  • I have a public key ASCeMjx_gYCCYo0NODk4IOl_3j65pDlUlTeC0DDjfnowDgo

To claim this, I am signing this object:

@dixon
dixon / gist:4b31dc4245943d32766075fe95c418e4
Created November 16, 2017 18:19
jQuery.extend vs Object.assign when dealing with null and undefined
var o = { test: 'asdfasdf' }
> undefined
$.extend({}, o, { test: null })
> {test: null}
$.extend({}, o, { test: undefined })
> {test: "asdfasdf"}
Object.assign({}, o, { test: null })
@dixon
dixon / SaltySailorChat.user.js
Last active January 25, 2018 01:41
UserScript for Chat Stack Exchange, that adds dark theme and sidebar-hiding
// ==UserScript==
// @name Salty Sailor Chat
// @version 0.1
// @description chat goodness, e.g. sidebar hiding, dark theme
// @author Jarrod Dixon
// @include /https?://chat\..*stackexchange.com/rooms/\d+/.*/
// ==/UserScript==
(function() {
'use strict';
@dixon
dixon / gist:8dc9c0131546b09ace683a78c937d037
Created June 14, 2016 17:35
Dark Theme for chat.stackexchange.com
#input-area {
background: #252525 !important;
}
#input {
color: #aaa !important;
background-color: #252525 !important;
}
#sidebar {
@dixon
dixon / gist:86b705813ba67c37d204
Created April 1, 2015 18:38
elasticsearch local developer options to prevent network broadcasting/replication
# elasticsearch dev options
cluster.name: jarrod_elasticsearch # shouldn't just be elasticsearch - make it unique to your computer
node.local: true
discovery.zen.ping.multicast.enabled: false
index.number_of_shards: 1
index.number_of_replicas: 0
/// <summary>
/// Does a Step with the location of caller as the label.
/// </summary>
public static IDisposable StepHere(
this MiniProfiler profiler,
[CallerMemberName] string memberName = "",
[CallerFilePath] string sourceFilePath = "",
[CallerLineNumber] int sourceLineNumber = 0)
{
if (profiler == null) return null;