Skip to content

Instantly share code, notes, and snippets.

View reports.txt
10 Minified React error #130; visit[]=undefined&args[]= for the full message or use the non-minified dev environment for full errors and additional helpful warnings.
8 Cannot read property \'type\' of undefined
7 Cannot read property \'replace\' of undefined
6 The object can not be found here.
5 Failed to execute \'insertBefore\' on \'Node\': The node before which the new node is to be inserted is not a child of this node.
5 Cannot set property \'onload\' of null
5 Cannot read property \'unbind\' of undefined
4 Cannot read property \'tagName\' of undefined
3 Failed to execute \'removeChild\' on \'Node\': The node to be removed is not a child of this node.
View change.jsx
componentDidUpdate: function ( prevProps ) {
// update value state on preview mode change or value changed (via props) by another component
if ((this.props.previewMode && this.props.previewMode !== prevProps.previewMode) || this.props.value !== prevProps.value) {
value: this.emptyIfDefault(this.getCurrentInputValue()),
bitfade / init.el
Last active Aug 29, 2015
Easy motion bug test
View init.el
(require 'package)
(require 'evil)
(require 'evil-easymotion)
(evil-mode 1)
(evilem-default-keybindings "SPC")
bitfade / gist:ee91d7e8aff16364b9ff
Created Mar 2, 2015
Custom WordPress Media Uploader
View gist:ee91d7e8aff16364b9ff
(function ($) {
"use strict";
/*global wp,jQuery */
var CustomGalleryEdit,CustomFrame;
function customClasses() {
var media =;
var l10n = media.view.l10n;
bitfade / gist:4555047
Last active Sep 25, 2019
WordPress - Remove empty p tags for custom shortcodes
View gist:4555047
add_filter("the_content", "the_content_filter");
function the_content_filter($content) {
// array of custom shortcodes requiring the fix
$block = join("|",array("col","shortcode2","shortcode3"));
// opening tag
bitfade / filter.js
Last active Oct 5, 2018
WordPress 3.5 media upload, toolbar with custom filter
View filter.js
/*jslint undef: false, browser: true, devel: false, eqeqeq: false, bitwise: false, white: false, plusplus: false, regexp: false, nomen: false */
/*global wp,jQuery */
jQuery(document).ready(function($) {
if (!window.wp || ! {
var media =;
bitfade / gist:4460948
Last active Apr 3, 2017
WordPress 3.5 media upload api example
View gist:4460948
var workflow ={
title: 'Select the images',
// use multiple: false to disable multiple selection
multiple: 'add',
button: {
text: 'Add selected images'
library: {
type: 'image'
Author: bitfade
this class will convert a XML configuration in to a simpler object
package bitfade.utils {
import flash.xml.*
public class XmlParser {