When you run anchor init my_project, Anchor generates a massive boilerplate repository. Let's break down the most important files:
programs/my_project/src/lib.rsThis is where your actual Rust smart contract lives. It contains your state structs, your instruction contexts, and your program logic.
Anchor.tomlThis is the configuration file for your workspace. It defines:
When you run anchor build, Anchor parses your Rust code and generates a JSON file called the IDL.
This is the most important file for frontend developers. The IDL tells your React app exactly what instructions your program has, what arguments they expect, and what the state accounts look like.
Lesson Exam