How nicolaykopaas/t17-project2 works
Filmsøk is a film-and-series discovery app: users search and filter a large catalog, browse paginated results, open title details, add reviews, and maintain a personal list. The React client sends GraphQL operations through Apollo to a Yoga API; resolvers validate and dispatch catalog work to SQL-backed search and mutations. Request context supplies user identity and batched lookups, while artwork resolution can use TMDB. The README documents server-side sorting/filtering and cursor pagination; some frontend and backend modules were not sampled, so their internal wiring is left unspecified.
Main entry points: index.ts Query and mutations · routes.tsx Page routing · main.tsx App entry · TitlePage.tsx Title details
Components 20
Web client
- App entry
frontend/src/main.tsx - Page routing
frontend/src/routes.tsx - Search and browse
frontend/src/pages/HomePage.tsx - Search controls
frontend/src/components - Title details
frontend/src/pages/TitlePage.tsx - Review form
frontend/src/components/ReviewForm.tsx - Personal list
frontend/src/pages/MyListPage.tsx - GraphQL operations
frontend/src/graphql/operations.ts - Apollo transport
frontend/src/apollo/client.ts
GraphQL API
- GraphQL server
backend/src/app.ts - Schema definition
backend/src/schema.ts - Query and mutations
backend/src/resolvers/index.ts - Request context
backend/src/context.ts
Catalog services
- Input validation
backend/src/validation.ts - Catalog search
backend/src/search.ts - Cursor pagination
backend/src/keyset.ts - Artwork service
backend/src/artwork.ts
Data and integrations
- PostgreSQL
- TMDB
Other components
- Film seeker
Connections 23
- Film seeker → App entry: uses app
frontend/src/main.tsx - App entry → Page routing: installs router
frontend/src/main.tsx - Page routing → Search and browse: routes to
frontend/src/routes.tsx - Page routing → Title details: routes to
frontend/src/routes.tsx - Page routing → Personal list: routes to
frontend/src/routes.tsx - Search and browse → Search controls: renders
- App entry → Apollo transport: provides client
frontend/src/main.tsx - Title details → GraphQL operations: runs title query
frontend/src/pages/TitlePage.tsx - Review form → GraphQL operations: runs review mutation
frontend/src/components/ReviewForm.tsx - Title details → Review form: renders
frontend/src/pages/TitlePage.tsx - Apollo transport → GraphQL server: sends GraphQL
frontend/src/apollo/client.ts - GraphQL server → Schema definition: serves schema
backend/src/app.ts - GraphQL server → Request context: builds per request
backend/src/app.ts - Schema definition → Query and mutations: binds resolvers
- Query and mutations → Input validation: validates inputs
backend/src/resolvers/index.ts - Query and mutations → Catalog search: dispatches search
backend/src/resolvers/index.ts - Catalog search → PostgreSQL: queries catalog
backend/src/search.ts - Catalog search → Cursor pagination: encodes cursors
backend/src/search.ts - Query and mutations → PostgreSQL: writes reviews and list
backend/src/resolvers/index.ts - Request context → PostgreSQL: batches lookups
backend/src/context.ts - Query and mutations → Artwork service: resolves image URLs
backend/src/resolvers/index.ts - Artwork service → PostgreSQL: caches artwork
backend/src/artwork.ts - Artwork service → TMDB: fetches artwork