Skip to content

Instantly share code, notes, and snippets.

{
"keys": [
{
"kid": "docs-test-dev-2026-10",
"kty": "RSA",
"use": "sig",
"alg": "RS384",
"n": "1b4LarVV2kMJRAtiy52ctt0hTSjdlqleAPRNa5DG_qrIPJ0DoiB2ixRlk0VGyj-vkaiTc6GybiLi0y4EeaM5jkvdTSHOynnTqzpLlUtWi75wlGiDmSua6cCWcu1qmoAq19PN3RkETRymCwx1u4nva04NgYhhhQlfQkvjf8OANqvXg66FzXrRfrxcSMd5-2DD1m_QEOvjqF1cg8hgDmOGfZ9RfADhI2awxUghOKwrpZCXjf7lvrU1Tv9IjgK5zLrZmsMnQc1eXy3ZrZLW5Ky3T_OKGMDwlOt_2jwetXHuzcgeV7X1htzcRHueOFc4WkzOD1ahy6aE2V83UhCnFHfcBQ",
"e": "AQAB"
}
@lmiller1990
lmiller1990 / Test.json
Created October 22, 2026 22:36
Test.json
{"foo":"bar"}
@lmiller1990
lmiller1990 / README.md
Created September 19, 2025 11:16
Dead code elimination
npm install
npx rollup -c rollup.config.js

Output is

{
  console.log('someCode ran');
}
@lmiller1990
lmiller1990 / debruijn.py
Last active December 21, 2024 13:26
debruijn
from typing import Optional
class Node:
def __init__(self, label: str):
self.label = label
self.edge: Optional["Edge"] = None
class Edge:
@lmiller1990
lmiller1990 / readme.md
Created December 16, 2024 04:33
devcontainers

I am getting started with devcontainers - I have too many projects, and managing dependencies and versions is getting too tiring. We can automate it with devcontainers.

Example: With Java

I work with Java lately, let's start with that. Let's create a project

mkdir HelloWorld
mkdir -p com/example/HelloWorld
touch com/example/HelloWorld/Main.java
@lmiller1990
lmiller1990 / init.lua
Last active September 15, 2024 11:33
Neovim
vim.cmd("set expandtab")
vim.cmd("set number")
vim.cmd("set tabstop=2")
vim.cmd("set shiftwidth=2")
vim.cmd("set expandtab")
vim.g.mapleader = " "
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
@lmiller1990
lmiller1990 / code.py
Last active August 12, 2024 11:24
Pandas / Python / R
import pandas as pd
import json
from camel_converter import to_snake
def read(jsonfile):
with open(jsonfile, "r") as f:
return json.loads(f.read())
@lmiller1990
lmiller1990 / week1.py
Created July 24, 2024 10:10
Binf7000
import random
standardTranslation = {
"TTT": "F",
"TCT": "S",
"TAT": "Y",
"TGT": "C",
"TTC": "F",
"TCC": "S",
"TAC": "Y",
@lmiller1990
lmiller1990 / content.md
Created January 30, 2024 21:39
Questions for Basarat

Congrats!

You had your 20K sub special 3 months ago. You are now at 141K. Holy smokes! The growth is exponential.

Congrats, well deserved. You are one of my favorite creators - I don't watch every video, only so many hours in a day, but I always have a good time when I do! I first found you via your TypeScript handbook, that was very useful, thanks!

On Content

Looking at your videos, some are hugely popular (50K+) and others are sub 1K. The algorithm is fickle. I do see many other creators getting much more consistent view counts. Any thoughts on this, what they might be doing different?

@lmiller1990
lmiller1990 / lib.es5.d.ts
Created January 29, 2024 10:58
awaited.ts
type Awaited<T> = T extends null | undefined ? T : // special case for `null | undefined` when not in `--strictNullChecks` mode
T extends object & { then(onfulfilled: infer F, ...args: infer _): any; } ? // `await` only unwraps object types with a callable `then`. Non-object types are not unwrapped
F extends ((value: infer V, ...args: infer _) => any) ? // if the argument to `then` is callable, extracts the first argument
Awaited<V> : // recursively unwrap the value
never : // the argument to `then` was not callable
T; // non-object or non-thenable