The repository pattern separates data access from UI components. The component calls a repository function like getUsers() to get data. The repository fetches data from an API endpoint and returns it as JSON. The component waits for this data, then renders it in a list. This pattern hides how data is fetched, so the component code stays simple and focused on UI. The execution table shows each step: component starts, repository fetches, data is parsed, component receives data, and finally renders the list. Variables like 'users' start undefined and get assigned after data arrives. Beginners often wonder why the component waits for data or how the repository hides details. The key is the async call and abstraction. If the data source changes, only the repository code needs updating, not the component. This makes apps easier to maintain and test.