{"size": 171, "ext": "js", "max_stars_repo_path": "src/utils/url/index.js", "max_stars_repo_name": "hex0cter/cors-dev-proxy", "max_stars_repo_stars_event_min_datetime": null, "max_stars_repo_stars_event_max_datetime": null, "max_issues_repo_path": "src/utils/url/index.js", "max_issues_repo_name": "hex0cter/cors-dev-proxy", "max_issues_repo_issues_event_min_datetime": null, "max_issues_repo_issues_event_max_datetime": null, "max_forks_repo_path": "src/utils/url/index.js", "max_forks_repo_name": "hex0cter/cors-dev-proxy", "max_forks_repo_forks_event_min_datetime": "2019-10-04T17:55:36.000Z", "max_forks_repo_forks_event_max_datetime": "2019-10-04T17:55:36.000Z"}
{"max_stars_count": null, "max_issues_count": null, "max_forks_count": 1, "avg_line_length": 14.25, "max_line_length": 35, "alphanum_fraction": 0.5964912281}
const { URL } = require('url')

const isUrl = string => {
  try {
    return Boolean(new URL(string))
  } catch (e) {
    return false
  }
}

module.exports.isUrl = isUrl
