Skip to content

Instantly share code, notes, and snippets.

@productioncoder
Created November 18, 2018 13:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save productioncoder/a3f79a2e3f4034f24e421d515bc2864a to your computer and use it in GitHub Desktop.
Save productioncoder/a3f79a2e3f4034f24e421d515bc2864a to your computer and use it in GitHub Desktop.
Youtube in React: selector for next page token for most popular videos
const getMostPopular = (state) => state.videos.mostPopular;
export const getMostPopularVideosNextPageToken = createSelector(
getMostPopular,
(mostPopular) => {
return mostPopular.nextPageToken;
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment