Skip to content

Instantly share code, notes, and snippets.

View oller's full-sized avatar
🚲

David Ollerhead oller

🚲
View GitHub Profile
@oller
oller / vue-apollo.js
Created April 11, 2019 08:20
vue apollo config middleware link working for dynamic additional headers
import Vue from 'vue'
import VueApollo from 'vue-apollo'
import {
createApolloClient,
restartWebsockets
} from 'vue-cli-plugin-apollo/graphql-client'
import { setContext } from 'apollo-link-context'
import authConfig from '@/../auth_config.json'
const middlewareLink = setContext((_, { headers }) => {
@oller
oller / README.md
Last active August 10, 2017 13:45 — forked from kerryrodden/README.md
Zoomable sunburst with updating data

I combined Mike Bostock's Zoomable Sunburst and Sunburst Partition examples, so that I could have both zooming and updating the underlying data (between count and size, in this case). A simple combination of the examples does not work; you have to edit the arcTween function used for updating the data, so that when it redraws the partition layout, it takes account of the current zoom level by adjusting the domain of the x scale.

Click on any arc to zoom in, and click on the center circle to zoom out. Use the Size/Count radio buttons to update the data.

@oller
oller / README.md
Last active February 1, 2017 11:57 — forked from jefffriesen/README.md
Chrome SVG Performance Regression

An example of the Chrome performance regression handling complex SVGs

Steps to recreate

@oller
oller / flip-carousel.markdown
Created August 18, 2016 16:32
Flip Carousel
@oller
oller / d3-arc-path.js
Created February 16, 2016 15:17
arc path
var route = view.map.svg
.select(".transactions")
.append("path")
.datum({
type: "LineString",
coordinates: [routeCoords[0], routeCoords[1]]
})
.attr("class", "route")
.attr("d", view.map.path.projection(view.map.projection));
@oller
oller / index.html
Created January 22, 2016 13:54 — forked from d3noob/.block
World Map with zoom and pan
<!DOCTYPE html>
<meta charset="utf-8">
<style>
path {
stroke: white;
stroke-width: 0.25px;
fill: grey;
}
</style>
<body>
@oller
oller / gist:3bd30bc8ebd0b8bf25c9
Created July 14, 2015 14:11
Package Control.sublime-settings
{
"in_process_packages":
[
],
"install_prereleases": true,
"installed_packages":
[
"Alignment",
"AngularJS",
"Autoprefixer",
@oller
oller / gist:f494de40e84d86a77247
Created July 14, 2015 14:10
Preferences.sublime-settings
{
"always_show_minimap_viewport": true,
"bold_folder_labels": true,
"caret_extra_width": 3,
"caret_style": "phase",
"close_windows_when_empty": false,
"color_scheme": "Packages/Material Theme/schemes/Material-Theme.tmTheme",
"copy_with_empty_selection": false,
"detect_slow_plugins": true,
"drag_text": false,
%btn--social {
border-width: 1px;
border-style: solid;
color: #FFFFFF;
&:hover {
color: #FFFFFF;
}
.socicon {
position: relative;
top: 1px;
@oller
oller / Night.tmTheme
Created October 17, 2014 10:12
Sublime Theme
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>name</key>
<string>IceWorld - Night</string>
<key>settings</key>
<array>
<dict>
<key>name</key>