Skip to content

Instantly share code, notes, and snippets.

View tristan-f-r's full-sized avatar
πŸ‡ΊπŸ‡¦

Tristan F.-R. tristan-f-r

πŸ‡ΊπŸ‡¦
View GitHub Profile
@tristan-f-r
tristan-f-r / starship.toml
Created December 31, 2022 19:47
my starship config that i blatantly stole from someone else thanks kiel
format = """
[β”Œ](bold green)$status$cmd_duration$fill
[β”‚ ](bold green)$hostname$localip$time$nix_shell
[β”‚ ](bold green)$java$kotlin$rust$golang$python
[β”‚ ](bold green)$sudo$username$directory$package$git_branch$git_commit$git_state
[└─>](bold green) """
[fill]
symbol = "─"
@tristan-f-r
tristan-f-r / types.ts
Created November 22, 2023 16:16
strict map and filter types
interface Array<T> {
map<U>(
callbackfn: (value: T, index: number, array: T[]) => U,
thisArg?: unknown
): { [K in keyof this]: U };
filter<S extends T>(
callbackfn: (value: T, index: number, array: T[]) => value is S,
thisArg?: unknown
): { [K in keyof this]-?: this[K] extends S ? S : never }
}