Skip to content
>devspeak
← glossary
level 1Understanding Your Project

Library

also: libraries

A collection of ready-made code for a common task, like handling dates or drawing charts. Your code uses it when needed, so nobody rebuilds it from scratch.

a bit more technical

Reusable code that provides functions or components for a specific job, called by your own code when you choose. Libraries are usually installed as packages. Unlike a framework, a library doesn't dictate your app's overall structure.

picture it

A library is a toolbox. You pick up the hammer when you need a hammer. You decide how to build the house; the tools just help.

why it matters

Agents pick libraries constantly. Knowing a library is someone else's toolbox helps you ask good questions, like whether a heavy charting library is worth it for one small chart.

what your agent might say
agent
I'd use a library like Zod to check the form data. Writing those checks by hand would take longer and be easier to get wrong.
how you might use it
you → your agent
Which library are you planning to use for the calendar view? Give me two options with pros and cons before you pick one.
common mistake

Thinking a library and a framework are the same. You call a library when you want it. A framework calls your code and sets the structure of your whole app.

builds on