Skip to content

Instantly share code, notes, and snippets.

View geotrev's full-sized avatar
🏠
Working from home

George Treviranus geotrev

🏠
Working from home
View GitHub Profile
@geotrev
geotrev / Apollo-debunk.md
Created June 21, 2023 23:53
Apollo debunking

📣 I want to debunk Reddit’s claims, and talk about their unwillingness to work with developers, moderators, and the larger community, as well as say thank you for all the support

I wanted to address Reddit’s continued, provably false statements, as well as answer some questions from the community, and also just say thanks.

(Before beginning, to the uninitiated, “the Reddit API” is just how apps and tools talk with Reddit to get posts in a subreddit, comments on a post, upvote, reply, etc.)

Reddit: “Developers don’t want to pay”

Steve Huffman on June 15th: “These people who are mad, they’re mad because they used to get something for free, and now it’s going to be not free. And that free comes at the expense of our other users and our business. That’s what this is about. It can’t be free.”

@geotrev
geotrev / post-mirror.md
Last active June 9, 2023 04:20
Reddit - /r/ApolloApp post 6/8/2022 mirror

📣 Apollo will close down on June 30th. Reddit’s recent decisions and actions have unfortunately made it impossible for Apollo to continue. Thank you so, so much for all the support over the years. ❤️

Hey all,

It’s been an amazing run thanks to all of you.

Eight years ago, I posted in the Apple subreddit about a Reddit app I was looking for beta testers for, and my life completely changed that day. I just finished university and an internship at Apple, and wanted to build a Reddit client of my own: a premier, customizable, well-designed Reddit app for iPhone. This fortunately resonated with people immediately, and it’s been my full time job ever since.

Today’s a much sadder post than that initial one eight years ago. June 30th will be Apollo’s last day.

@geotrev
geotrev / eb-feedback-all.js
Last active November 28, 2021 04:49
Script to automatically add feedback to all sales/purchases
/**
* This script will automatically fill in all purchase feedback when viewing the below link.
*
* --> https://www.ebay.com/fdbk/leave_feedback
*
* Why? Leaving feedback is annoying. Let a script do it for you. It takes a basic
* configuration below and assigns 5 stars to everything. You can optionally
* change the feedback text for either a sale or purchase. It also assumes
* you've already left critical feedback for any given sale/purchase BEFORE
* running the script. In other words, it won't skip anything and you should
@geotrev
geotrev / fail.js
Created November 6, 2020 20:29
it's a fail
console.log(
(![] + [])[+[]] +
(![] + [])[+!+[]] +
([![]] + [][[]])[+!+[] + [+[]]] +
(![] + [])[!+[] + !+[]]
);
@geotrev
geotrev / tcg-player-add-card-script.js
Last active May 31, 2020 02:03
Add missing cards to collection
;(() => {
const productRows = document.querySelectorAll('tr[id^="StoreProductId_"]')
productRows.forEach((row) => {
const quantity = row.querySelector(".CollectionText").innerText
const value = row.querySelector('.minPrice').innerText
if (parseInt(quantity) > 0 || value === "$0.00") return
row.querySelector(".CollectionUpArrow").click()
@geotrev
geotrev / live-exp-active-element.js
Last active February 1, 2024 15:23
Active Element Live Expression
/**
* This script recursively checks `shadowRoot`s and `contentDocument`s until the true `activeElement` is found.
*
* HOW TO USE: Copy and paste this into your Chrome dev tools in the `Create live expression` input.
*/
(function(){function d(){var u=arguments[0]||document.activeElement;if(u.shadowRoot&&u.shadowRoot.activeElement){return d(u.shadowRoot.activeElement)}if(u.contentDocument&&u.contentDocument.activeElement){return d(u.contentDocument.activeElement)}return u}return d()})();
/**
Unminified version:
@geotrev
geotrev / framework-thoughts.md
Last active April 1, 2020 20:57
Things To Consider in a UI library tool

Libraries for building UI have become all the rage. React, Vue, Stencil, LitElement, Svelte... the list goes on. Enabling developers to build UI easily and efficiently is a chief concern in the front end world, and the ecosystem is filled with options.

But what goes into a UI library? What defines the core features and capabilities of a UI library?

At the same token, what ISN'T the concern of a UI library? What are the "out of scope" features that other tools should handle?

Library Concerns:

  • Returns View Code: Writing a template that later becomes native to the platform. E.g., string template -> HTML.
  • Web Components: Ingests CSS: This is the opposite of the above - the library should intake CSS (only CSS, and not Sass or Less) for styling.
  • State: Internal state that informs the resulting UI
@geotrev
geotrev / tic-tac-toe.js
Last active March 3, 2020 01:26
Tic Tac Toe
class TicTacToe {
constructor() {
this.handleMouseEnter = this.handleMouseEnter.bind(this)
this.handleMouseLeave = this.handleMouseLeave.bind(this)
this.handleClick = this.handleClick.bind(this)
this.handleResetClick = this.handleResetClick.bind(this)
this.tiles = []
this.start()
}
@geotrev
geotrev / deploy.sh
Created January 3, 2020 02:54
Bash Script: Auto Deploy to gh-pages Branch
#!/usr/bin/env bash
set -o nounset
set -o errexit
set -o pipefail
git config user.name "$USER_NAME"
git config user.email "$USER_EMAIL"
# Add github to known_hosts to enable push from CI
@geotrev
geotrev / config.yml
Created January 3, 2020 02:46
Circle CI Config for GH Pages
version: 2
jobs:
build:
working_directory: ~/repo-working-dir
docker:
- image: circleci/ruby:2.6.5-node-browsers
steps:
- checkout
- save_cache: