Skip to content

Instantly share code, notes, and snippets.

@ja-k-e
ja-k-e / code.tsx
Last active December 6, 2022 23:30
ChatGPT sequence creating an accessible button component
/*
create an accessible button component using react and typescript with
variant, size, element, aria label, and optional href props
*/
import React, { ButtonHTMLAttributes } from "react";
type ButtonProps = ButtonHTMLAttributes<HTMLButtonElement> & {
variant?: "primary" | "secondary" | "tertiary";
size?: "small" | "medium" | "large";

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

Keybase proof

I hereby claim:

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

To claim this, I am signing this object:

@ja-k-e
ja-k-e / README.md
Last active May 11, 2017 16:38
Stopwatch: Timing tasks in a pretty way.

Stopwatch

Timing things in a pretty way

  • instantiate
  • mark events at points in time
  • generate a report
stopwatch = Stopwatch.new('StopWatch Test')
stopwatch.mark 'Hello, World'
@ja-k-e
ja-k-e / stop_words.json
Last active May 10, 2017 01:39
List of Stop Words
{
"stop_words": [
"a",
"about",
"above",
"across",
"after",
"afterwards",
"again",
"against",
@ja-k-e
ja-k-e / iterm_rails_highlighting.md
Last active September 29, 2016 22:44
iTerm Rails Highlighting

Hey! Lets make our rails server logs nice.

In iTerm, we can color regex matches to make things less gross.

To do so, you should create a new profile explicitly for rails server. Open iTerm prefs and create a new one.

You can map a shortcut to it, and even add an initial command at startup

@ja-k-e
ja-k-e / jokes.md
Last active October 19, 2020 15:31
Jokes
What do you call... _
a presidential lacrosse player's pig's social network a bro's ham's linkedin
an online store for throat lozenges cough eshop
it when two people crouched fight over tea chai knees feud
mucus that floats phlegm buoyant
the space between a soul singer's intervals throatis leading
your favorite knife after it's been knighted? Sir Rated

| Did you hear about... | _ |

@ja-k-e
ja-k-e / application_controller.rb
Created November 3, 2015 00:20 — forked from scottwb/application_controller.rb
Get a list of all the filters on a given Rails 3 controller.
# Add these methods to your ApplicationController. Then, any controller
# that inherits from it will have these methods and can programmatically
# determine what filters it has set.
class ApplicationController < ActionController::Base
def self.filters(kind = nil)
all_filters = _process_action_callbacks
all_filters = all_filters.select{|f| f.kind == kind} if kind
all_filters.map(&:filter)
end
@ja-k-e
ja-k-e / 2015_css_dev_conf_jokes.md
Last active October 30, 2015 22:42
CSS Dev Conf Jokes
  • pants come off for bed
  • feet come off for bed
  • fuckin, fuckin, belly...bellyflop the octopus
  • letter opener katana

bfto

@ja-k-e
ja-k-e / spacing.js
Last active September 18, 2015 19:01
Spacing Prefs
//
// greet paul
greeting("Paul");
//
// greeting method to take name and return a greeting
function greeting(subject) {