{"size": 727, "ext": "js", "max_stars_repo_path": "src/pages/Results/actions.js", "max_stars_repo_name": "edmarfelipe/react-tube", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/pages/Results/actions.js", "max_issues_repo_name": "edmarfelipe/react-tube", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/pages/Results/actions.js", "max_forks_repo_name": "edmarfelipe/react-tube", "max_forks_repo_forks_event_min_datetime": null, "max_forks_repo_forks_event_max_datetime": null}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": null, "avg_line_length": 16.9069767442, "max_line_length": 52, "alphanum_fraction": 0.6423658872}
export const LOADING = 'RESULTS_LOADING'
export const SUCCESS = 'RESULTS_SUCCESS'
export const LOADING_NEXT = 'RESULTS_LOADING_NEXT'
export const LOAD_NEXT = 'RESULTS_LOAD_NEXT'

export function sucess(items, nextPageToken) {
  return {
    type: SUCCESS,
    payload: {
      videos: items,
      nextPageToken: nextPageToken
    }
  }
}

export function loading() {
  return {
    type: LOADING,
    payload: {
      videos: []
    }
  }
}

export function loadingNextPage() {
  return {
    type: LOADING_NEXT,
    payload: {
      videos: []
    }
  }
}

export function loadNextPage(items, nextPageToken) {
  return {
    type: LOAD_NEXT,
    payload: {
      videos: items,
      nextPageToken: nextPageToken
    }
  }
}
