{"size": 611, "ext": "js", "max_stars_repo_path": "lib/api/utils/logger.js", "max_stars_repo_name": "Davidislit/mimic", "max_stars_repo_stars_event_min_datetime": "2017-01-18T01:50:43.000Z", "max_stars_repo_stars_event_max_datetime": "2022-02-13T08:43:51.000Z", "max_issues_repo_path": "lib/api/utils/logger.js", "max_issues_repo_name": "Davidislit/mimic", "max_issues_repo_issues_event_min_datetime": "2017-01-15T22:00:42.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-02T02:37:04.000Z", "max_forks_repo_path": "lib/api/utils/logger.js", "max_forks_repo_name": "Davidislit/mimic", "max_forks_repo_forks_event_min_datetime": "2017-01-29T09:52:27.000Z", "max_forks_repo_forks_event_max_datetime": "2022-02-09T14:52:34.000Z"}
{"max_stars_count": 347, "max_issues_count": 120, "max_forks_count": 48, "avg_line_length": 24.44, "max_line_length": 76, "alphanum_fraction": 0.58101473}
const consoleColorsSupported = typeof navigator !== "undefined" &&
                               navigator.userAgent &&
                               navigator.userAgent.indexOf('Chrome') !== -1;

export function logGroup(collapsed = false, groupName, ...params) {
  const args = consoleColorsSupported
    ? [groupName, ...params]
    : [groupName.replace(/%c/g, '')];

  if (!console.group) {
    console.log(...args);
    return;
  }

  console[`group${collapsed ? 'Collapsed' : ''}`](...args);
}

export function logGroupEnd(name) {
  if (!console.groupEnd) {
    return;
  }

  console.groupEnd(name);
}
