TLDR Web Dev

TLDR WEB DEV 2024-10-28

5 sections15 entrieslinks blockcomplete parse

Parse notes

  • Subscription/account footer truncated before parsefooter_truncated

01ARTICLES & TUTORIALS

HOW WE SHRUNK OUR JAVASCRIPT MONOREPO GIT SIZE BY 94%

A Microsoft team working with a massive JavaScript monorepo (1JS) faced a challenge: the repository size had ballooned to 178GB. The issue stemmed from two key problems: keeping thousands of files in a single folder and a flawed packing algorithm that led to inefficient compression of files with similar names, especially CHANGELOG files. To address the folder issue, the team implemented a pull request and automated cleanup pipelines. The packing issue was tackled by repacking the repo with a larger window and utilizing a new path-walk algorithm, resulting in a reduction from 178GB to 5GB.

jonathancreamer.com7 min read

UNDERSTANDING ROUND ROBIN DNS

Round Robin DNS is a method of load balancing by distributing traffic across multiple servers. Browsers like Safari select the closest server based on latency, while Cloudflare consistently picks a random server regardless of its proximity or availability.

blog.hyperknot.com8 min read

DELICIOUS DONUT COMPONENTS

Component composition in React Server Components (RSC) allows for creating flexible UIs and avoiding prop drilling. While composition works similarly in both client and server components, there are important distinctions when interleaving them. This article discusses these differences, including limitations on function passing and the use of `React.cloneElement()`, and provides alternative strategies for sharing state across server and client boundaries.

frontendatscale.com13 min read

02OPINIONS & ADVICE

WRITES AND WRITE-NOTS

The widespread use of AI will create a division between "writes" and "write-nots," with the former being those who can still write and the latter those who rely on AI for writing. This shift will result in a decline in the ability to think clearly, as writing is an essential tool for developing and expressing thought.

paulgraham.com3 min read

HOW NOT TO DISAGREE

When a team leader disagrees with a managerial decision, they should not oppose it publicly but instead commit to executing it effectively. By doing so, they avoid creating a victim mentality within the team and preserve their credibility.

boz.com3 min read

03LAUNCHES & TOOLS

MDX

Mdx is a command-line tool that allows you to execute code blocks within Markdown files. It provides features like argument passing, dependency definition, and shebang support.

github.comGitHub repository

AGENT.EXE

Agent.exe is an Electron app that lets Claude 3.5 Sonnet control your local computer directly.

github.comGitHub repository

BETTER UPLOAD

Better Upload is a React library that simplifies file uploads to S3-compatible services. It offers a streamlined setup, customizable server-side logic, and pre-built UI components.

better-upload.js.orgTool

04MISCELLANEOUS

BEFORE YOU BUY A DOMAIN NAME, FIRST CHECK TO SEE IF IT'S HAUNTED

This developer bought a domain name, musicbox.fun, unaware that it had a history of copyright violations. This past activity negatively impacted the domain's reputation with search engines, causing the developer's website traffic to plummet. Before buying a domain, check for such “haunted” domains by using the Wayback Machine, searching for DMCA complaints, and examining historical SEO data.

bryanbraun.com8 min read

DETECTING WHEN LLMS ARE UNCERTAIN

Reasoning in LLMs can be improved by utilizing adaptive sampling techniques that take into account the model's uncertainty. A project called Entropix measures uncertainty using entropy and varentropy, which quantify the distribution of the predicted tokens. It then uses different sampling methods based on these metrics, including argmax sampling for high confidence, branching for multiple possibilities, and inserting "thinking" tokens for low confidence.

thariq.io7 min read

OUR OPTIMIZERS NEED A RETHINK

Compiler and database optimizers may need a significant rethink to improve their understandability, controllability, and testability. Current shortcomings of optimizers include limited user control, difficulty in debugging optimization misses, and lack of proper testing capabilities. These can be solved by providing clearer documentation, developing improved tooling for debugging optimization failures, allowing users to provide explicit guidance to the optimizer, and creating regression testing infrastructure.

typesanitizer.com14 min read