Skip to content

Instantly share code, notes, and snippets.

View rosszurowski's full-sized avatar

Ross Zurowski rosszurowski

View GitHub Profile
@rosszurowski
rosszurowski / .deploy
Last active September 23, 2024 14:52
A Makefile template for Kirby CMS with esbuild and tailwindcss
.htaccess
index.php
favicon.svg
favicon.png
assets/
media/index.html
kirby/
site/accounts/index.html
site/blueprints/
site/cache/index.html
@rosszurowski
rosszurowski / export.go
Last active March 10, 2022 17:14
Download images from a Squarespace export file
package main
import (
"context"
"encoding/xml"
"flag"
"fmt"
"io"
"log"
"net/http"
@rosszurowski
rosszurowski / subscribe.md
Last active February 16, 2024 14:52
How to subscribe to the Small Seasons calendar via iCal.

Small Seasons via iCal

If you'd like to follow along with the small seasons calendar via iCal, you'll want to create a new calendar subscription. On Mac, you can do this by going to File > New Calendar Subscription…

Into the panel that opens, paste the following URL:

https://calendar.google.com/calendar/ical/4eu29iflrjlhahh3kusp454n2c%40group.calendar.google.com/private-3f3d86651493934f026c4aca11baaf02/basic.ics

Here's a list of resources for learning React.

In general, I find the best way to learn something is to have a project to try it out with. These resources and tutorials are a good way to support your own project-based learning.

Introduction

Intro to React (link)

An official tutorial from the React team that walks you from zero to building a simple game. It does a great job of introducing all the core React concepts in simple language.

@rosszurowski
rosszurowski / un-country-centroids.json
Last active February 18, 2022 15:32
A compiled list of coordinates for all 193 countries in the UN. Compiled from this list of UN members (https://en.wikipedia.org/wiki/Member_states_of_the_United_Nations#Current_members), and this list of country centroids (http://gothos.info/resources/).
[
{ "name": "Afghanistan", "lat": 33, "long": 66 },
{ "name": "Albania", "lat": 41, "long": 20 },
{ "name": "Algeria", "lat": 28, "long": 3 },
{ "name": "Andorra", "lat": 42.5, "long": 1.5 },
{ "name": "Angola", "lat": -12.5, "long": 18.5 },
{ "name": "Antigua and Barbuda", "lat": 17.05, "long": -61.8 },
{ "name": "Argentina", "lat": -34, "long": -64 },
{ "name": "Armenia", "lat": 40, "long": 45 },
{ "name": "Australia", "lat": -25, "long": 135 },

I hereby claim:

  • I am rosszurowski on github.
  • I am rosszurowski (https://keybase.io/rosszurowski) on keybase.
  • I have a public key ASCO0gSAqgnGK91zdDer_TJW-oTr_bZBjfh6P9Sz-zxfhgo

To claim this, I am signing this object:

@rosszurowski
rosszurowski / data.json
Created September 22, 2015 17:05
Force-directed text editor
{
"nodes":[
{"name":"Myriel","group":1},
{"name":"Napoleon","group":1},
{"name":"Mlle.Baptistine","group":1},
{"name":"Mme.Magloire","group":1},
{"name":"CountessdeLo","group":1},
{"name":"Geborand","group":1},
{"name":"Champtercier","group":1},
{"name":"Cravatte","group":1},
@rosszurowski
rosszurowski / timestamp.html
Last active August 29, 2015 14:19
Custom Elements
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Timestamp Demo</title>
</head>
<body>
<x-timestamp>05/05/2015</x-timestamp>
<script src="timestamp.js"></script>
</body>
@rosszurowski
rosszurowski / nerp.js
Created December 10, 2014 13:37
An n-th degree polynomial interpolator. Used as an alternative for common `lerp` functions
/**
* N-th degree polynomial interpolation
* @param {Number} degree
* @param {Number} min
* @param {Number} max
* @param {Number} amount
* @returns {Number}
*/
function nerp(degree, min, max, amount) {
return min + Math.pow(amount, degree) * (max - min);
@rosszurowski
rosszurowski / lerp-color.js
Last active September 24, 2024 23:19
Linear interpolation for hexadecimal colors.
/**
* A linear interpolator for hexadecimal colors
* @param {String} a
* @param {String} b
* @param {Number} amount
* @example
* // returns #7F7F7F
* lerpColor('#000000', '#ffffff', 0.5)
* @returns {String}
*/