Skip to content

Instantly share code, notes, and snippets.

View joostdevries's full-sized avatar

Joost de Vries joostdevries

  • Amsterdam, Netherlands
View GitHub Profile
@joostdevries
joostdevries / gist:f2ce4f24dc16ae8c2d10
Created September 30, 2014 12:01
github-related-issues.user.js
// Adds a 'References' section to the github issue/PR sidebar
//
// Installation:
// - Save this file as github-related-issues.user.js somewhere
// - Go to chrome://extensions
// - Drag the file to the open extensions tab
(function(w) {
var $ = function(selector, one) {
return one?document.querySelector(selector):document.querySelectorAll(selector);
@joostdevries
joostdevries / gist:acd9f47583111542982b
Last active August 29, 2015 14:04
IE9 parentNode error in Emberjs

I get reports from users experiencing the error below in IE9 causing our (EmberJS) application to crash. I haven't found what's causing it yet because I'm unable to reproduce it through Browserstack or locally and I've got users in IE9 without problems (only a couple of users are affected).

Error

Unable to get value of the property 'parentNode': object is null or undefined

User agent

@joostdevries
joostdevries / gist:6060936
Created July 23, 2013 08:53
Using the werkzeug debugger if you're testing AJAX calls to your API.
$(window).ajaxError(function(evt, evtData) {
if(evtData && ('responseText' in evtData)) {
var debuggerWindow = window.open('about:blank', 'debuggerWindow');
debuggerWindow.document.open();
debuggerWindow.document.write(evtData.responseText);
debuggerWindow.document.close();
}
});