Get AI summaries of any video or article — Sign up free
I don’t really use libraries anymore thumbnail

I don’t really use libraries anymore

Theo - t3․gg·
6 min read

Based on Theo - t3․gg's video on YouTube. If you like this content, support the original creators by watching, liking and subscribing to their content.

TL;DR

AI-assisted coding lowers the practical cost of replacing some dependencies, while supply-chain and version risks make each additional dependency feel more dangerous.

Briefing

Software teams are increasingly treating many third-party libraries as liabilities—something to delete, rewrite, or even replace with prompts—because AI makes reimplementation cheaper while dependency risk keeps compounding. The core shift is psychological and practical: the “cost” of not understanding a dependency is rising, while the “cost” of generating an alternative is falling. That combination is pushing developers to rethink what belongs in package.json and what should live inside their own codebase.

The argument starts with the smallest, most meme-able packages—like is odd or leftpad—where the functionality is essentially a few lines of code. Those packages became popular because npm made reuse effortless, but that convenience also encouraged teams to adopt code they barely understand. Supply-chain threats, version churn, and dependency chains that obscure what’s actually safe are real risks, especially when a project’s package.json becomes a “glossary” of transitive dependencies. Yet the transcript draws a pointed comparison: the same people who criticize dependency sprawl often also criticize AI-assisted coding, even though AI can reduce the need for those tiny libraries by letting less experienced developers generate the code directly.

From there, the discussion expands to larger, harder-to-replace libraries where the tradeoff isn’t “two lines vs one import,” but operational reliability. A concrete example is Tkumi, used to render React components on the server to generate images for the T3 chat “wrapped” feature. Tkumi wouldn’t bundle in production, and once shipped it caused production errors that took the service down for about 25 seconds. After reverting and troubleshooting for roughly 15 minutes, the solution was to “vibe code” a client-side JavaScript workaround. That change reduced server-side capability and altered the user experience (images had to be generated client-side), but it restored stability and let the team control layout details like spacing, word wrapping, and aesthetics—areas where AI agents struggled when trying to automate the rendering pipeline.

The transcript then connects this pattern to broader dependency categories: some libraries exist beyond a developer’s knowledge (useful for beginners or for complex domains), while others exist because reimplementation is tedious. Even when a library is technically “cool,” maintenance and extensibility matter—especially when future features (login, blogs, sessions, SEO via server rendering) might require architectural flexibility. Next.js is cited as an example of a framework that can absorb many future needs even if it’s not perfectly understood.

A key conceptual model is “complexity vs capability.” As capability rises, willingness to adopt external code drops—particularly for complex problems—because teams now feel they can generate or adapt solutions. The transcript claims this bends the old linear relationship between problem difficulty and dependency adoption.

Finally, it argues that the replacement for libraries may increasingly be prompts and code copied into the repo. The transcript cites a quote from Simon “Sty Pete” (as referenced) about preferring prompt requests over pull requests because prompts preserve intent. It also highlights tools and practices that make this feasible: copying code directly (as with shadcn-style approaches), using codebase-aware agent tooling (like BTCA, which clones the repo and uses search tools rather than token-heavy doc indexing), and using AI code review tools (Code Rabbit) to keep generated changes safe.

The takeaway is not “never use libraries,” but “measure risk differently.” Some dependencies are worth forking, some are worth buying, and some should be avoided or replaced—because AI lowers reimplementation friction while supply-chain and maintenance risks keep growing. The transcript closes with a challenge: uninstall packages, or accept that this is a real shift in how modern teams decide what to depend on.

Cornell Notes

AI is making it easier to replace third-party libraries with generated code or repo-local prompts, while dependency risk (supply-chain attacks, version breakage, opaque transitive chains) keeps getting worse. The transcript argues that this changes how developers calculate whether to keep a dependency: perceived risk rises, perceived reimplementation cost falls. Concrete examples include removing Tkumi after bundling and production failures, and using AI to rewrite or work around problematic components. It also frames a broader trend: prompts may become “the new library,” and codebase-first approaches (copying into the repo, cloning for agent search) make AI-driven development more reliable. The result is a shifting “complexity vs capability” curve for adopting dependencies.

Why does the transcript claim tiny npm packages like is odd or leftpad became a problem beyond just being “meme code”?

They’re easy to replace (often a one-liner), so adopting them can reflect missing understanding. That matters because every dependency adds supply-chain and maintenance risk: transitive dependency chains become harder to audit, packages can change behavior across versions, and malicious updates are possible. The transcript argues that AI-assisted coding can eliminate the need for these “pad the string” style imports, reducing risk without losing functionality.

What went wrong with Tkumi, and how did the team respond?

Tkumi was used to render React components on the server to generate images for the T3 chat wrapped feature. It failed to bundle in production, and after shipping it caused production errors that took the service down for about 25 seconds. After reverting and spending roughly 15 minutes troubleshooting, the team replaced the approach with a client-side JavaScript “vibe coded” solution. That restored stability but required compromises: rendering moved to the client, and the image generation behavior changed (the wrapped link no longer had a server-generated image).

How does the transcript distinguish when libraries still make sense?

It splits libraries into categories. Some solve problems beyond a developer’s knowledge (often helping beginners), while others exist because reimplementing them would be tedious. It also emphasizes maintenance and extensibility: frameworks like Next.js can reduce future pain by absorbing many features (SEO, server rendering, login/session patterns) even if the developer doesn’t fully understand every internal detail.

What is the “complexity vs capability” idea, and how does it change dependency decisions?

The transcript proposes that as developers become more capable, they become less willing to adopt external solutions—especially for complex problems—because they can generate or adapt alternatives with AI. It also notes a psychological shift: reimplementation feels easier now, while dependency risk feels scarier because each additional package increases the supply-chain surface area. This bends the old linear relationship between problem difficulty and willingness to import dependencies.

Why does the transcript say prompts may replace libraries?

Prompts can capture intent and can be copied into a repo, letting teams generate behavior without pulling in extra packages. A cited quote (from “Sty Pete”) argues that prompt requests communicate intent better than many pull requests, since code diffs don’t always explain why changes were made. The transcript also claims that AI agents can work better when the relevant code or instructions live inside the project, not buried in external dependencies or poorly structured documentation.

What role do codebase-first practices play in making AI-driven development more reliable?

The transcript argues that AI handles real code better than messy docs. Examples include shadcn-style approaches that copy component code directly into the repo, and BTCA, which clones the whole codebase and uses built-in search/tools (rather than token-heavy doc indexing like some MCP approaches). That increases the chance agents can find how things work and make accurate modifications.

Review Questions

  1. Pick one library example from the transcript (Tkumi, ink, bun, Next.js, or is odd/leftpad). What specific risk or friction made it a candidate for removal, forking, or replacement?
  2. How does the transcript’s “complexity vs capability” model predict dependency adoption behavior as developer capability increases?
  3. What does “prompts are the new library” mean in practice, and what conditions make it more likely to work (e.g., code living in the repo, agent search, documentation quality)?

Key Points

  1. 1

    AI-assisted coding lowers the practical cost of replacing some dependencies, while supply-chain and version risks make each additional dependency feel more dangerous.

  2. 2

    Tiny utility packages can be a net risk when teams adopt code they barely understand; AI can generate the equivalent directly.

  3. 3

    Operational reliability can outweigh feature completeness: Tkumi’s production bundling/runtime failures led to a client-side rewrite despite losing some server-rendered benefits.

  4. 4

    Dependency decisions increasingly depend on perceived risk and control: teams should ask whether they can influence a dependency, contribute to it, or need to maintain it themselves.

  5. 5

    Some dependencies remain valuable because reimplementation is genuinely tedious or because frameworks provide extensibility (e.g., Next.js for future features like SEO and server rendering).

  6. 6

    Prompts may function as reusable “instructions” that preserve intent and can be copied into a repo, reducing reliance on external packages.

  7. 7

    Codebase-first workflows (copying code into the repo, cloning for agent search) tend to outperform doc-heavy approaches for AI agents making correct changes.

Highlights

Tkumi’s bundling and production behavior became severe enough to take T3 chat down for about 25 seconds, prompting a revert and a client-side rewrite.
The transcript argues that dependency risk feels higher now because each package adds supply-chain surface area, while AI makes reimplementation feel cheaper.
A central prediction: prompts are becoming a substitute for libraries—especially when code and instructions live inside the repo where agents already operate.
The “complexity vs capability” curve is no longer linear: higher capability reduces willingness to import external solutions, particularly for complex problems.

Topics

Mentioned