Skip to content

Instantly share code, notes, and snippets.

View nshoes's full-sized avatar
👨‍🎨
changing my code editor's theme

Nate Shoemaker nshoes

👨‍🎨
changing my code editor's theme
View GitHub Profile
export const GoogleApi = function(opts) {
opts = opts || {}
const apiKey = opts.apiKey;
const libraries = opts.libraries || [];
const client = opts.client;
const URL = 'https://maps.googleapis.com/maps/api/js';
const googleVersion = '3.22';
let script = null;
@7ictor
7ictor / partial-update.js
Last active April 26, 2018 10:13
CouchDB update handler for partial updates of a document.
function (doc, req) {
var findTheChanges = function (prevK, obj) {
var arr = [];
for (var key in obj) {
var prevKey = prevK || '';
if (obj.hasOwnProperty(key)) {
var value = obj[key];
// If its an Object dig deeper.
if (value !== null &&
typeof value === 'object' &&
@MichalZalecki
MichalZalecki / await-async.js
Created November 13, 2015 05:16
Run generators and and await/async
import axios from "axios";
export default async function () {
const { data: { id } } = await axios.get("//localhost:3000/id");
const { data: { group } } = await axios.get("//localhost:3000/group");
const { data: { name } } = await axios.get(`//localhost:3000/${group}/${id}`);
console.log(name); // Michał
}
@jdstein1
jdstein1 / Destiny-API-reference.md
Last active November 11, 2020 23:34
A list of APIs for player data in Bungie's Destiny

Destiny API reference

A list of APIs for player data in Bungie's Destiny

Groups

Clans

API - Clan

@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active April 27, 2024 00:18
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname