Skip to content

Instantly share code, notes, and snippets.

View arthyn's full-sized avatar
🏹
Seeking truth through creation

Hunter Miller arthyn

🏹
Seeking truth through creation
View GitHub Profile

Keybase proof

I hereby claim:

  • I am arthyn on github.
  • I am arthyn (https://keybase.io/arthyn) on keybase.
  • I have a public key ASCLfmGj4u2BnqXrmqTjID4LQitUcFzgZxiSZv0OQ8e42go

To claim this, I am signing this object:

@arthyn
arthyn / load-typekit.js
Created May 18, 2017 15:55
Load typekit
try{Typekit.load({ async: true });}catch(e){}
/**
* Function: runWithDebugger
* Runs callback with debugger initiated
*
* Params:
* callback - the function you want to debug
* args - the array of arguments being passed to the callback
* Return:
* result of callback
*/
@arthyn
arthyn / library-system.js
Created October 2, 2017 03:41
LibrarySystem with Dependencies
(function() {
var libraryStorage = {};
var Library = function(dependencies, callback) {
this.dependencies = dependencies;
this.generator = callback;
};
function retreiveLibrary(libraryName) {
var library = libraryStorage[libraryName];
@arthyn
arthyn / useHistoryMemorizer.ts
Last active June 16, 2021 13:32
Last "external" route tracking
import { useEffect } from 'react';
import { useLastLocation } from 'react-router-last-location';
import create from 'zustand';
type LocationMap = {
[key: string]: string | undefined;
};
type HistoryStore = {
locations: LocationMap;
@arthyn
arthyn / embed-updates.patch
Created April 28, 2022 18:13
embed updates
diff --git a/pkg/interface/src/logic/lib/suspend.ts b/pkg/interface/src/logic/lib/suspend.ts
index 1d6d5f4688..63e497afa9 100644
--- a/pkg/interface/src/logic/lib/suspend.ts
+++ b/pkg/interface/src/logic/lib/suspend.ts
@@ -4,7 +4,7 @@ export interface Suspender<T> {
read: () => T;
}
-export function suspend<T>(awaiting: Promise<T>): Suspender<T> {
+export function suspend<T>(awaiting: Promise<T>, defaultValue?: any): Suspender<T> {
@arthyn
arthyn / homestead-install.md
Last active May 2, 2022 23:25
Homestead Install Steps
  1. Clone or pull latest homestead and urbit repos if you haven't , making sure you've run git lfs install && git lfs checkout in the urbit repo for pills
  2. Boot a fake ship if you haven't making sure to use: urbit -F zod -B /path/to/urbit-repo/bin/solid.pill
  3. Create new desks
    1. |merge %garden our %base
    2. |mount %garden
    3. |merge %homestead our %base
    4. |mount %homestead
  4. From the urbit repo:
    1. rsync -avL --delete pkg/base-dev/* ~/zod/garden/ we delete here to clear the directory
@arthyn
arthyn / s3-lib.hoon
Last active May 17, 2022 04:02
s3-lib
=, scr:crypto
|_ [reg=@t secret=@t key=@t now=@da]
+$ purl purl:eyre
++ auth-dbg
|= =request:http
=/ canonical (canonical request)
=/ digest (hash (crip canonical))
=/ contract (contract request digest)
:* canonical=canonical
digest=digest