{"size": 469, "ext": "js", "max_stars_repo_path": "plugins/hacktoberfest.js", "max_stars_repo_name": "ianychoi/hacktoberfest-checker", "max_stars_repo_stars_event_min_datetime": "2020-10-11T10:58:22.000Z", "max_stars_repo_stars_event_max_datetime": "2022-03-29T13:54:12.000Z", "max_issues_repo_path": "plugins/hacktoberfest.js", "max_issues_repo_name": "ianychoi/hacktoberfest-checker", "max_issues_repo_issues_event_min_datetime": "2020-10-11T10:08:56.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-28T00:16:32.000Z", "max_forks_repo_path": "plugins/hacktoberfest.js", "max_forks_repo_name": "ianychoi/hacktoberfest-checker", "max_forks_repo_forks_event_min_datetime": "2020-10-11T10:04:07.000Z", "max_forks_repo_forks_event_max_datetime": "2020-11-02T02:38:54.000Z"}
{"max_stars_count": 16, "max_issues_count": 254, "max_forks_count": 40, "avg_line_length": 21.3181818182, "max_line_length": 57, "alphanum_fraction": 0.6780383795}
import hacktoberfestConfig from '../hacktoberfest.config'

const now = new Date()

const hacktoberfest = {
  ...hacktoberfestConfig,
  started: () => {
    const startDate = new Date(hacktoberfestConfig.start)

    return startDate.getTime() < now.getTime()
  },
  ended: () => {
    const endDate = new Date(hacktoberfestConfig.end)

    return endDate.getTime() < now.getTime()
  },
}

export default (context, inject) => {
  inject('hacktoberfest', hacktoberfest)
}
