Background
Many apps using IGDB need a game detail page that fetches a single game by slug or ID and renders summary, release date, rating, and cover art.
Proposed change
Add a copyable example file that uses the typed query builder to fetch one game and buildImageUrl() to build a cover image URL.
Acceptance criteria
- Uses
.first() or .findById() accurately.
- Selects only fields needed by the detail view.
- Handles a missing game or missing cover image gracefully.
- Calls
client.dispose() in a finally block like the existing examples.
Files likely involved
examples/game-detail.ts
examples/README.md
docs/examples.md
Background
Many apps using IGDB need a game detail page that fetches a single game by slug or ID and renders summary, release date, rating, and cover art.
Proposed change
Add a copyable example file that uses the typed query builder to fetch one game and
buildImageUrl()to build a cover image URL.Acceptance criteria
.first()or.findById()accurately.client.dispose()in afinallyblock like the existing examples.Files likely involved
examples/game-detail.tsexamples/README.mddocs/examples.md