Skip to content

Instantly share code, notes, and snippets.

@tallykatt
tallykatt / load-external-script-snippet.js
Created July 24, 2016 23:35 — forked from cou929/load-external-script-snippet.js
Simple code snippet for loading external script from a bookmarklet.
/**
* load-external-script-snippet.js
* Kosei Moriyama <cou929@gmail.com>
*
* Simple code snippet for loading external script from a bookmarklet.
* Replace example url of script to your target script url before use.
*/
(function() {
var u = 'http://example.com/bookmarklet.js';
@tallykatt
tallykatt / firebase.js
Created July 25, 2016 01:56
firebase hack
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){
window.firebase = require('firebase')
},{"firebase":2}],2:[function(require,module,exports){
/**
* Firebase libraries for browser - npm package.
*
* Usage:
*
* firebase = require('firebase');
@tallykatt
tallykatt / debug.js
Created July 25, 2016 01:16 — forked from dftaiwo/debug.js
JS Console Logging For Production & Debug Builds
var debugMode=false;
//.....
function logMessage() {
if(!debugMode) return;
console.log(Array.prototype.slice.call(arguments) );
}
@tallykatt
tallykatt / 0_reuse_code.js
Created December 22, 2016 19:01
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@tallykatt
tallykatt / bookmarklet.js
Created December 17, 2016 04:56 — forked from elidupuis/bookmarklet.js
How to create a bookmarklet with an external js file.
// use this code as your href attribute on your 'Install this bookmarklet' anchor tag.
// borrowed from http://net.tutsplus.com/tutorials/javascript-ajax/create-bookmarklets-the-right-way/
javascript:(function(){var jsCode = document.createElement('script');jsCode.setAttribute('src', 'http://example.com/path/to/file.js');document.body.appendChild(jsCode);}());
@tallykatt
tallykatt / jqueryinfirebug.js
Created July 25, 2016 02:32 — forked from hugueslamy/jqueryinfirebug.js
Load JQuery from Firebug console
j=document.createElement("SCRIPT");
j.src="http://code.jquery.com/jquery-latest.pack.js";
document.getElementsByTagName("HEAD")[0].appendChild(j);
@tallykatt
tallykatt / index.html
Created July 25, 2016 02:23 — forked from chrisalbright/index.html
Bookmarklets :)
<a href='javascript:(function(){var a=alert,b=Date,c=Number,d="";if("undefined"!=typeof window.getSelection){var e=window.getSelection();if(e.rangeCount){for(var f=document.createElement("div"),g=0,h=e.rangeCount;g<h;++g)f.appendChild(e.getRangeAt(g).cloneContents());d=f.innerHTML}}else"undefined"!=typeof document.selection&&"Text"==document.selection.type&&(d=document.selection.createRange().htmlText);a(new b(c(d)));})();'>Parse Epoch</a>
@tallykatt
tallykatt / core.scss
Created July 25, 2016 02:23 — forked from mateusortiz/core.scss
core.scss
/* ---------------------------------------- *\
VARIABLES
\* ---------------------------------------- */
$red: #a32c28;
$white: #fff;
$lightest-grey: #eee;
@tallykatt
tallykatt / live.js
Created July 25, 2016 02:21 — forked from ewistrand/live.js
Livereload script
/*
Live.js - One script closer to Designing in the Browser
Written for Handcraft.com by Martin Kool (@mrtnkl).
Version 4.
Recent change: Made stylesheet and mimetype checks case insensitive.
http://livejs.com
http://livejs.com/license (MIT)
@livejs