This file contains hidden or 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
// Module imports | |
import { bindActionCreators } from 'redux' | |
import { | |
connect, | |
Provider, | |
} from 'react-redux' | |
import React from 'react' | |
This file contains hidden or 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' | |
/******************************************************************************\ | |
Module imports | |
\******************************************************************************/ | |
const { URL } = require('url') | |
const cookie = require('koa-cookie') | |
const next = require('next') | |
const path = require('path') |
This file contains hidden or 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
// Component imports | |
import i18next from './i18next' | |
export default class extends React.Component { | |
constructor (props) { | |
super(props) |
This file contains hidden or 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 React from 'react' | |
export default Head extends React.Component { | |
componentWillMount () { | |
ga.push(location.pathname) // This probably isn't quite right, but you get the idea. | |
} | |
render () { | |
<div> | |
<script dangerouslySetInnerHTML={{__html: 'GA Snippet'}} /> |
This file contains hidden or 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
// Private property, cannot from the importing file | |
let bar = 'baz' | |
export default class Foo { | |
constructor () { | |
console.log(bar) | |
} | |
} |
This file contains hidden or 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 * bodyBuilder (next) { | |
this.body = { | |
links: {}, | |
meta: { | |
start_ms: Date.now() | |
} | |
} | |
yield next |
This file contains hidden or 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
#!/usr/bin/env python | |
import pprint | |
import sys | |
sys.path.append('../pgoapi') | |
from pgoapi import PGoApi | |
position = (43.060792, -89.410350, 0) |
This file contains hidden or 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 Backbone from 'backbone' | |
import template from 'templates/BlogList.hbs' | |
export default class BlogList extends Backbone.Marionette.ItemView { |
This file contains hidden or 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
[ | |
{ | |
$project: { | |
successful: { | |
$cond: ['$successful', 1, 0] | |
} | |
}, | |
}, { | |
$group: { | |
_id: null, |
This file contains hidden or 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 _, getRoutes, getSchemas; | |
_ = require( 'lodash' ); | |
getSchemas = function ( mongoose ) { | |
var docs, models; | |
docs = {}; | |
models = mongoose.models; |