If you're using a high-end bluetooth headset on your Macbook Pro it's likely your mac is using an audio codec which favors battery efficiency over high quality. This results in a drastic degradation of sound, the SBC codec is the likely culprit, read more about it here.
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
node_modules | |
dist/ | |
yarn.lock | |
wwwroot |
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 { join } from 'path' | |
import { readdir, stat } from 'fs-promise' | |
async function rreaddir (dir, allFiles = []) { | |
const files = (await readdir(dir)).map(f => join(dir, f)) | |
allFiles.push(...files) | |
await Promise.all(files.map(async f => ( | |
(await stat(f)).isDirectory() && rreaddir(f, allFiles) | |
))) | |
return allFiles |
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 trimSvgWhitespace() { | |
// get all SVG objects in the DOM | |
var svgs = document.getElementsByTagName("svg"); | |
// go through each one and add a viewbox that ensures all children are visible | |
for (var i=0, l=svgs.length; i<l; i++) { | |
var svg = svgs[i], | |
box = svg.getBBox(), // <- get the visual boundary required to view all children |
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
<!-- This is the HTML element that, when clicked, will cause the popup to appear. --> | |
<button id="open-popup">Subscribe to our mailing list</button> |
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
var app = require('app'); // Module to control application life. | |
var BrowserWindow = require('browser-window'); // Module to create native browser window. | |
var loki = require('lokijs'), | |
db = new loki(), | |
users = db.addCollection('users', { | |
indices: ['username'] | |
}); | |
users.insert({ username: 'joe', age: 40}); | |
users.insert({ username: 'jack', age: 30}); |
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
// Reference: http://www.blackdogfoundry.com/blog/moving-repository-from-bitbucket-to-github/ | |
// See also: http://www.paulund.co.uk/change-url-of-git-repository | |
$ cd $HOME/Code/repo-directory | |
$ git remote rename origin bitbucket | |
$ git remote add origin https://github.com/mandiwise/awesome-new-repo.git | |
$ git push origin master | |
$ git remote rm bitbucket |
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
var loki = require('lokijs'), | |
db = new loki('test.json'), | |
db2 = new loki('test.json'); | |
var users = db.addCollection('users'); | |
users.insert({ | |
name: 'joe' | |
}); | |
users.insert({ | |
name: 'john' |
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
/** | |
* Created by Robert Kehoe on 09/06/2014. | |
* MIT Licensed. | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining | |
* a copy of this software and associated documentation files (the | |
* "Software"), to deal in the Software without restriction, including | |
* without limitation the rights to use, copy, modify, merge, publish, | |
* distribute, sublicense, and/or sell copies of the Software, and to | |
* permit persons to whom the Software is furnished to do so, subject to |
NewerOlder