Skip to content

✏️ Refactor Providers Component #1165

@maxh1231

Description

@maxh1231

Is your feature request related to a problem or need? Please describe.

Currently, the Providers component accepts a showType and id prop and calls the getTvProviders or getMovieProviders requests. Instead of passing the component the applicable data to render an individual provider.

While this isn't inherently bad, with the ability to append watch/providers to the getTvDetails and getMovieDetails (which we're already doing), it may be better to pull the necessary data from those requests and pass it to the component. This would also eliminate a request.

Additional context

The original thought with this component may have been to render providers based on the signed-in user's set country of origin, which would require the standalone getWatchProviders request. However, I'm not sure that we're prepared to implement that functionality. I believe the watch/providers query parameter defaults to US.

Component implements providers.results.US.flatrate.map() - hardcoded US providers

Providers data included in getTvProviders and getMovieProviders:
Image

Perhaps @Thenlie can opine on this, and this issue in general.

Sub-issues

Metadata

Metadata

Assignees

Labels

Projects

Status

📋 Backlog

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions