These are dev notes for me, small things I look up regularly. You may find them useful.

Simple Patterns in TypeScript

Some of these have alternative options. Only listing my preference here.

Immutables

const simpleArray1: string[] = ["a", "b", "c"];

const simpleArray2: number[] = [1, 2, 3];

const simpleObject: { a: string; b: number } = { a: "a", b: 1 };

Function

const combineArrays = (arr1: any[], arr2: any[]): any[] => {
  return [...arr1, ...arr2];
};

This is why const makes sense here...

const sayNothing: Function = () => {};

Types

type Gate = "AND" | "OR";

type GameBoardProps = {
  id: number;
  usernId: string;
  gate: Gate;
  condition: conditionFunc;
};

export type conditionFunc = (item: string) => boolean;

Custom Hooks

const usePageData = (page: number, fn: Function) => {
  useEffect(() => {
    console.log("your hook-needing behaviour in here");
    fn(page);
  }, []);
};
Longer notes, all in Google Docs for now:
Things I didn't make but I find extremely useful: