Skip to content

Instantly share code, notes, and snippets.

@ilovecomputers
ilovecomputers / mastodonMostFavs.js
Last active February 22, 2023 04:10
Sort your mastodon posts by most favs
class FetchUtil {
/**
* @param {string|URL} url
* @param {Object} body
* @returns {Promise<Response>}
*/
static async post(url, body) {
return FetchUtil.#fetchResponse(url, {
method: "POST",
/*
** N I U 95
** Merely a compiled copy of cybre.space's M A S T O D O N 95 theme: https://github.com/cybrespace/mastodon/blob/cybrespace/app/javascript/styles/win95.scss
** and I modified the start menu sidebar height.
**
** Modify the height rule for the `getting-started__footer::after` selector to suit your instance
**
** To use this style:
** Install Stylus for Firefox: https://addons.mozilla.org/en-US/firefox/addon/styl-us/?src=search
** or Chrome: https://chrome.google.com/webstore/detail/stylus/clngdbkpkpeebahjckkjfobafhncgmne?hl=en
@ilovecomputers
ilovecomputers / DragMe.js
Last active August 12, 2018 19:10
Drag Me browser snippet
"use strict";
/**
* Drag Me is based on this Kirupa snippet: https://www.kirupa.com/html5/drag.htm
*
* It allows you to translate an element by dragging it instead of tediously modifying the css text. However, this will blast away any transform applied on the element before, so modify setTranslate to your needs.
*
* Add it as a Chrome DevTools Snippet or a Firefox DevTools Scratchpad. Either way, when you run it:
*
* 1. Select the element in your browser's element inspector
### Keybase proof
I hereby claim:
* I am ilovecomputers on github.
* I am ilovecomputers (https://keybase.io/ilovecomputers) on keybase.
* I have a public key whose fingerprint is B544 5CF0 18A3 59BA 8F60 60A0 EFEE 57E2 5334 D25D
To claim this, I am signing this object:
@ilovecomputers
ilovecomputers / gist:97aa3e0592cc65758bbd
Last active August 29, 2015 14:23
Creating an fs-based blog system using Promises
/**
* The problem: I have a Dumb Blog System that is based on a directory structure like so:
* .
* |-- A Blog
* | |--postOne.txt
* | |--postTwo.txt
* | |--postThree.txt
* | |--PUBLISHED
* |-- B Blog
* |-- thisScript.js