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
Verifying that "caseywebb.id" is my Blockstack ID. https://onename.com/caseywebb |
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 Persistable from './_persistable' | |
type Exchange = | |
'coinbase' | | |
'hitbtc' | |
type CurrencySymbol = | |
'USD' | | |
'BTC' | | |
'ETH' | |
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 * as Bluebird from 'bluebird' | |
import * as db from './db' | |
import Persistable from './_persistable' | |
beforeAll(() => db.connect()) | |
afterEach(() => db.drop()) | |
afterAll(() => db.disconnect()) | |
test('persistable abstract class adds `create', async () => { | |
const name = 'foos' |
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 ko from 'knockout' | |
import Router from 'ko-component-router' | |
Router.useRoutes({ | |
'/user/:id': ['user-show', loadUser, | |
{ | |
'/': 'user-overview', | |
'/todos': ['user-todos' loadUserToDos] | |
} | |
] |
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 ko from 'knockout' | |
import Router from 'ko-component-router' | |
ko.components.register('app', { | |
template: '<ko-component-router params="routes: routes"></ko-component-router>', | |
viewModel: class App { | |
constructor() { | |
this.routes = { | |
'/user/:id/!': [loadUser, 'user-show'] | |
} |
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 events from '../events' | |
const COURSE_TYPES = new Map([ | |
['/', 0], | |
['/on-demand', 1], | |
['/live', 2], | |
['/assessment', 4] | |
]) | |
export default { |
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
'use strict' | |
const { each } = require('lodash') | |
incrementTabCount() | |
window.addEventListener('unload', decrementTabCount) | |
window.addEventListener('storage', (e) => { | |
if (e.key === 'getSessionStorage') { | |
// Some tab asked for the sessionStorage |
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
const { concat, endsWith, flatMap, includes, map, reduce } = require('lodash') | |
const routes = require('./routes') | |
function createSiteMap(routes) { | |
return reduce(routes, (accum, { routes: children }, route) => | |
concat(accum, | |
children | |
? flatMap(createSiteMap(children), (child) => { | |
let r = route + child | |
r = r.replace(new RegExp('//', 'g'), '/') |
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
'use strict' | |
let _; const { each, map, some, every } = _ = require('lodash') | |
const ko = require('knockout') | |
const $ = require('jquery') | |
const Query = require('ko-querystring').default | |
module.exports = class LinkList { | |
constructor({ | |
sections, |
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
'use strict' | |
const spawn = require('cross-spawn') | |
const byline = require('byline') | |
const gulp = require('gulp') | |
const eslint = require('gulp-eslint') | |
module.exports = (done) => { | |
const diff = spawn('git', ['--no-pager', 'diff', '--cached', '--name-only', '*.js']) | |
const scripts = [] |