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
import {auth, credential, initializeApp} from "firebase-admin"; | |
// Call this before starting the server | |
export function init() { | |
const serviceAccount = { | |
clientEmail: process.env.FIREBASE_SERVICE_ACCOUNT_CLIENT_EMAIL, | |
privateKey: process.env.FIREBASE_SERVICE_ACCOUNT_PRIVATE_KEY, | |
projectId: process.env.FIREBASE_SERVICE_ACCOUNT_PROJECT_ID | |
}; |
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
import Vue from 'vue'; | |
Vue.component('v-alert', {}); | |
Vue.component('v-app', {}); | |
Vue.component('v-autocomplete', {}); | |
Vue.component('v-avatar', {}); | |
Vue.component('v-badge', {}); | |
Vue.component('v-bottom-nav', {}); | |
Vue.component('v-bottom-sheet', {}); | |
Vue.component('v-breadcrumbs', {}); |
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
// ==UserScript== | |
// @name Github Browse At Last Commit | |
// @namespace behindthemath.io | |
// @version 0.1 | |
// @description Adds a button to browse the current file on the tree of the last commit | |
// @author BehindTheMath | |
// @match http*://*github.com/*/*/blob/* | |
// @grant none | |
// ==/UserScript== | |
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { |
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
// utils.ts | |
export module MathUtils { | |
export function degreesToRadians(degrees: number): number { | |
return degrees * Math.PI / 180; | |
} | |
export function radiansToDegrees(radians: number): number { | |
return radians * 180 / Math.PI; | |
} | |
}; |
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
/** | |
* Wraps <code>document.querySelector()</code> and <code>document.querySelectorAll()</code> to either: | |
* | |
* a) return the matching {@link Element} or {@link NodeListOf<Element>} as soon as possible: immediately if it's already | |
* available in the DOM, or as soon as it's ready, by using <code>setInterval()</code>. | |
* | |
* or | |
* | |
* b) resolve when the specified element(s) are no longer present in the DOM. | |
* |
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
// ==UserScript== | |
// @name Show Retailmenot codes | |
// @namespace behindthemath.io | |
// @include /.*retailmenot.com\/view\/[^\?]*$/ | |
// @version 1 | |
// @grant none | |
// ==/UserScript== | |
(function () { | |
var dataNewTab = document.querySelectorAll('a.button-show-code')[0].getAttribute('data-new-tab'); |
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
// ==UserScript== | |
// @name Fix links in Google search results with ";wap2" | |
// @description Remove ";wap2" from the end of links in Google search results | |
// @namespace behindthemath.io | |
// @include *google.com/search?q=* | |
// @version 1 | |
// @grant none | |
// ==/UserScript== | |
(function removeWap2 () { |
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
// ==UserScript== | |
// @name Download Youtube playlist as MP3s | |
// @namespace behindthemath.io | |
// @include http://www.youtubecomtomp3.com/YouTube-Playlist-Downloader.php | |
// @version 1 | |
// @grant none | |
// ==/UserScript== | |
(function () { | |
console.log("Running..."); |
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 KohlsCashFwd() { | |
//Define the variables | |
//The From field must include the entire text of the From field, including the name | |
var fromEmail = "Kohl's <Kohls@t.kohls.com>"; | |
var subject = "Nice work! Here's your Kohl's Cash."; | |
//Date format is yyyy/mm/dd | |
var afterDate = "2016/05/21"; | |
var forwardEmail = "test@gmail.com"; |