Skip to content

Instantly share code, notes, and snippets.

@wzulfikar
wzulfikar / observations.md
Last active November 13, 2022 10:53
Observations. Thoughts.

▲▼▲

This gist is a part of my public notes. Here's the "sitemap" of the notes:

flowchart TD
  Notes -.-> Problem-based
  Notes --You are here--> Observations[<strong>Observations</strong>]
  Notes -.-> Logs
 Notes -.-&gt; Challenges
@wzulfikar
wzulfikar / electronics.md
Last active October 19, 2022 21:20
Electronics and their utilities.

Electronics

I like to know the actual utilities that an electronic device actually give me. This gist documents my attempt to understand the utilities of such devices.

▲▼▲

This gist is a part of my public notes. Here's the "sitemap" of the notes:

flowchart TD
@wzulfikar
wzulfikar / challenges.md
Last active November 3, 2022 11:46
Self Challenge

Challenges

Self-challenge for self-improvement.

Example of challenge (eg. weekly):

Sun Mon Tue Wed Thu Fri Sat Score
Ch. 1: No screen 30 minutes before sleep
Start Mon, Oct 17, 2022
◻️ ◻️ ◻️ ◻️ ◻️ ◻️ ◻️ A | B | C
@wzulfikar
wzulfikar / .Brewfile
Last active May 10, 2024 20:09
My Brewfile. Generated using `brew bundle dump --global`
tap "facebook/fb"
tap "ggozad/formulas"
tap "heroku/brew"
tap "homebrew/bundle"
tap "homebrew/cask-fonts"
tap "homebrew/services"
tap "lokalise/cli-2"
tap "mongodb/brew"
tap "oven-sh/bun"
brew "act"
@wzulfikar
wzulfikar / .aliases
Last active May 10, 2024 20:40
Shell aliases I use every day.
alias zshso="source ~/.zshrc"
alias zshedit="nano ~/.zshrc"
alias clr="clear"
alias cl="clear"
alias hist=history
alias ytdl="youtube-dl" # Example: ytdl https://www.youtube.com/watch?v=BBJa32lCaaY
alias graph="graph-easy" # Example: echo '[a],[c]->[b]' | graph --as=boxart
alias pn="pnpm" # Example: pn i (install packages from package.json)
alias cat="bat -p" # Replace cat with bat (plain style)
@wzulfikar
wzulfikar / notes.md
Last active November 2, 2022 18:24
Notes

Hello world! 🌎

I write notes in this gist as comments. My original goal was to have a workflow where I can't have an excuse to not write. No websites to manage, no codes to push, no styles to update. Just write. I found Github gist fitting and I don't have issues with writing markdown.

This gist contains "problem-based", technical notes. I encounter a problem, I "google" the solution, I document the solution. Hopefully, I can accumulate the learning and don't have to google again when I encounter the same problem.

Besides problem-based, I also write my "TIL" notes here. They are the new things I learnt that often gave me that "nice" feeling when I first found about it.

There are other things I write like electronics, observations, etc. which I put in different gists. If you want to check it, here's the "sitemap" of all my notes:

@wzulfikar
wzulfikar / mermaid_test.md
Last active September 15, 2022 18:06
Mermaid: Test mermaid diagram in gist.
@wzulfikar
wzulfikar / lexorank-example.ts
Last active August 30, 2022 01:25
Lexorank example in TS
import sortBy from "lodash/sortBy"; // https://github.com/kvandake/lexorank-ts
import { LexoRank } from "lexorank";
const cards = [
{ id: 1, rank: "", flag: "0" }, // flag 0: first card, flag 1: last card. We use flag so we don't have to recalculate first and last card.
{ id: 2, rank: "", flag: "" },
{ id: 3, rank: "", flag: "1" },
];
function parseRank(rank: string) {
@wzulfikar
wzulfikar / pull_request_template.md
Last active October 12, 2022 18:30
PR Template

🚧 Work in progress

What

What does this PR change, add, or delete?

Why

Why is this PR needed?

Screenshots

| Before | After |

@wzulfikar
wzulfikar / greeting.ts
Created August 20, 2022 21:44
DEV.to Post: Typing for Next.js API - pages/api
import { ApiHandler, handle, z } from "@backend";
const schema = z.object({
query: z.object({
name: z.string(),
}),
});
export const response = z.object({
greeting: z.string(),