Bring Live Movie Data Into Matinee
Bring Live Movie Data Into Matinee
The interface already looks like Matinee, but the page is still working from local values. In this module you will connect the app to TMDB so the movie grid and genre chips are backed by live data instead of a prepared list. The work begins in the data layer, where we will build a small, reusable request helper and then expose focused functions for the screens that need movie data.
The first part of the module is intentionally low-level. You will set up the environment value the app needs, build the common request function, and make the TMDB response available through typed application functions. Then you will wire those functions into the home page without changing the page’s visual structure.
Pay attention to the direction of the data. The page asks lib/tmdb.ts for movies; lib/tmdb.ts talks to TMDB; the page receives the application-shaped values back. That separation will make later lessons much easier because discovery controls and movie details can reuse the same data layer.
By the end of this module, opening / will be enough to trigger real TMDB requests and render the real movie catalog and featured genres through the existing Matinee interface. Next we will make those controls drive the results.