I hereby claim:
- I am pakastin on github.
- I am pakastin (https://keybase.io/pakastin) on keybase.
- I have a public key ASAyvzrXmMhdv7DV6wjK3SMZMi7eyAg62enEY5dXMFGZUAo
To claim this, I am signing this object:
export function dispatch(el, eventName, payload) { | |
el || (el = document); | |
el = el.el || el; | |
var event = new CustomEvent(eventName); | |
event.details = payload || {}; | |
el.dispatchEvent(event); | |
} | |
export function listen(el, eventName, callback) { | |
el || (el = document); |
export default function storeFactory(obj) { | |
var element = document.createElement('div'); | |
element.setAttribute('data-store', true); | |
var store = {}; | |
store._element = element; | |
store._listeners = {}; | |
store.listen = (name, callback) => { | |
element.addEventListener(name, e => { |
import { svg } from 'redom'; | |
export class Icon { | |
constructor () { | |
this.el = svg('svg', { viewBox: '0 0 512 512' }, | |
this.g = svg('g', | |
this.path = svg('path') | |
) | |
); | |
} |
I hereby claim:
To claim this, I am signing this object:
const CACHE = 'site-name-here'; | |
self.addEventListener('fetch', (event) => { | |
event.respondWith(fetch(event.request) | |
.then((response) => { | |
if (!response || response.status !== 200 || response.type !== 'basic') { | |
return response; | |
} | |
const clonedResponse = response.clone(); |
#!/bin/bash | |
consolidated_file="./consolidated.json" | |
for i in $(find . -name '*.shp'); do | |
if [ ! -f "$consolidated_file" ]; then | |
# first file - create the consolidated output file | |
ogr2ogr -f GeoJSON $consolidated_file -t_srs EPSG:4326 $i | |
else | |
# update the output file with new file content | |
ogr2ogr -f GeoJSON -update -append $consolidated_file -t_srs EPSG:4326 $i | |
fi |
for (let i = 1; i < 100; i++) { | |
console.log(fizzBuzzLine(i)); | |
} | |
function fizzBuzzLine (number) { | |
const divisibleBy3 = divisibleBy(number, 3); | |
const divisibleBy5 = divisibleBy(number, 5); | |
if (divisibleBy3 && divisibleBy5) { | |
return 'FizzBuzz'; |