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.
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.
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.
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.
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.
Which library are you planning to use for the calendar view? Give me two options with pros and cons before you pick one.
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.