Skip to content

Instantly share code, notes, and snippets.

katelovescode / App.js
Created January 27, 2022 15:58
useEffect for Rack Mini Profiler in a React SPA on top of Rails
View App.js
import React, { useEffect } from 'react'
import './App.css'
const App = () => {
useEffect(() => {
const script = document.createElement('script')
script.async = true
script.src =
script.type = 'text/javascript'
katelovescode /
Last active December 28, 2021 16:19
PR Template

🔙 Backend tests

If you wrote 'em, or if this doesn't touch backend code, delete this section.

Frontend tests

If you wrote 'em, or if this doesn't touch frontend code, delete this section.

📋 Summary

A summary of your changes here (can defer to commit messages too).

Steps to set up locally (optional)

A list of things you need to change to get the code going.

  • Any new environment variables
  • Any build steps
katelovescode / earned_revenue
Last active October 19, 2021 15:17
Sequence Diagram - Earned Revenue
View earned_revenue
User->>+ServiceDay: earned_revenue
loop attendances
Attendance-->>ServiceDay: time_in_care, absence
ServiceDay->>+ServiceDay: duration(attendances.time_in_care)
ServiceDay->>+StateDurationRules: duration_type(self)
StateDurationRules-->>ServiceDay: duration_type
ServiceDay->>+ChildCasePeriod: authorized_units(duration_type)
ChildCasePeriod-->>ServiceDay: authorized_units
katelovescode / ruby-tricks.rb
Last active September 22, 2020 14:22
Ruby Tricks
View ruby-tricks.rb
Hash.key(value) # returns key by its value

Keybase proof

I hereby claim:

  • I am katelovescode on github.
  • I am katelovescode ( on keybase.
  • I have a public key ASBnoQBWeQzuWR3kBXkATJuoopmG5H42x4d-ZOT4PR-JMgo

To claim this, I am signing this object:

katelovescode /
Last active September 20, 2018 17:03
Questions I'm asking on the job hunt

Round 1

  • Tell me about the state of your current product and where you'd like to see it go in the next two years. What are your engineering goals?
  • What responsibilities would I have in the role I'm being considered for?
  • What would you say are the top two personality traits someone needs to do this job well?
  • Why are you hiring for this position?
  • How are you currently making product decisions? What are you hoping to change about that process, if anything?

Round 2

katelovescode / roman_numeral_converter.rb
Created September 7, 2018 22:20
Convert from Roman Numerals to Arabic
View roman_numeral_converter.rb
require "pry"
"m": 1000,
"d": 500,
"c": 100,
"l": 50,
"x": 10,
"v": 5,
"i": 1
katelovescode / facebook.css
Last active September 16, 2018 15:43
User Stylesheet to stop Facebook from displaying chat windows
View facebook.css
# Use the User CSS Chrome extension, navigate to facebook, double click the User CSS icon to
# display the slide-out CSS window, and add the following code to the page so your Facebook
# messenger chat windows don't display
#pagelet_dock, #pagelet_sidebar {
display: none;
katelovescode /
Last active September 19, 2019 18:30
Get Marginalized Folks in Tech and Keep Them There