{"size": 677, "ext": "js", "max_stars_repo_path": "asset/rules/global-require.js", "max_stars_repo_name": "awebdeveloper/eslint-config-generator", "max_stars_repo_stars_event_min_datetime": "2017-05-02T10:41:12.000Z", "max_stars_repo_stars_event_max_datetime": "2022-02-28T16:40:40.000Z", "max_issues_repo_path": "asset/rules/global-require.js", "max_issues_repo_name": "awebdeveloper/eslint-config-generator", "max_issues_repo_issues_event_min_datetime": "2017-06-21T13:42:26.000Z", "max_issues_repo_issues_event_max_datetime": "2018-01-07T14:13:24.000Z", "max_forks_repo_path": "asset/rules/global-require.js", "max_forks_repo_name": "awebdeveloper/eslint-config-generator", "max_forks_repo_forks_event_min_datetime": "2018-01-06T16:02:30.000Z", "max_forks_repo_forks_event_max_datetime": "2021-04-16T20:36:01.000Z"}
{"max_stars_count": 17, "max_issues_count": 2, "max_forks_count": 3, "avg_line_length": 22.5666666667, "max_line_length": 86, "alphanum_fraction": 0.5332348597}
ESLintConfigGenApp.rules["global-require"] = [
  {
    key: "rules.global-require",
    showIf: config => config.env.node == true,
    hint: `Enforce require() on the top-level module scope
          (<a href='http://eslint.org/docs/rules/global-require'>global-require</a>)`,
    variants: [
      {
        hint: "Allow local require",
        code: `function foo() {
  if (condition) {
    var fs = <mark>require("fs");</mark>
  }
}`,
        skip: true
      },
      {
        hint: "Dont Allow local require",
        code: `var fs = <mark>require("fs");</mark>
function foo() {
  if (condition) {
    //do something
  }
}`,
        value: ["error"]
      }
    ]
  }
];
