{"size": 1936, "ext": "js", "max_stars_repo_path": "packages/eslint-config/index.js", "max_stars_repo_name": "fisker/shared-configs", "max_stars_repo_stars_event_min_datetime": "2020-04-02T13:24:32.000Z", "max_stars_repo_stars_event_max_datetime": "2022-02-21T15:45:51.000Z", "max_issues_repo_path": "packages/eslint-config/index.js", "max_issues_repo_name": "fisker/shared-configs", "max_issues_repo_issues_event_min_datetime": "2019-04-19T08:54:57.000Z", "max_issues_repo_issues_event_max_datetime": "2022-03-25T11:26:48.000Z", "max_forks_repo_path": "packages/eslint-config/index.js", "max_forks_repo_name": "fisker/shared-configs", "max_forks_repo_forks_event_min_datetime": "2019-06-22T04:02:06.000Z", "max_forks_repo_forks_event_max_datetime": "2020-06-01T22:04:41.000Z"}
{"max_stars_count": 5, "max_issues_count": 878, "max_forks_count": 2, "avg_line_length": 23.3253012048, "max_line_length": 86, "alphanum_fraction": 0.5924586777}
module.exports = {
  root: true,
  parser: require.resolve('@babel/eslint-parser'),
  env: {
    browser: true,
    node: true,
  },
  parserOptions: {
    ecmaVersion: 'latest',
    sourceType: 'module',
    requireConfigFile: false,
    allowImportExportEverywhere: true,
    ecmaFeatures: {
      globalReturn: false,
      jsx: true,
    },
    babelOptions: {
      babelrc: false,
      configFile: false,
      parserOpts: {
        plugins: ['exportDefaultFrom'],
      },
    },
  },
  reportUnusedDisableDirectives: true,
  extends: [
    // ESLint recommended
    './rules/recommended.js',

    // plugins
    './plugins/import.js',
    './plugins/promise.js',
    './plugins/node.js',
    './plugins/unicorn.js',
    './plugins/eslint-comments.js',
    './plugins/regexp.js',
    './plugins/sonarjs.js',

    // airbnb
    'eslint-config-airbnb-base',
    './rules/best-practices.js',
    './rules/errors.js',
    './rules/es6.js',
    './rules/imports.js',
    './rules/node.js',
    './rules/strict.js',
    './rules/style.js',
    './rules/variables.js',

    // prettier
    './plugins/prettier.js',
  ].map((id) => require.resolve(id)),
  rules: {
    // should not set by `eslint-plugin-node`,
    // and also there is a option by `eslint-config-unicorn`
    'no-process-exit': 'off',

    // conflicts with `unicorn/prevent-abbreviations` auto fixing
    'no-underscore-dangle': 'off',

    quotes: [
      'error',
      'single',
      {
        avoidEscape: true,
        allowTemplateLiterals: false,
      },
    ],

    'import/extensions': ['error', 'always', {ignorePackages: true}],

    // Default options seems not working without second option
    'import/order': ['error', {}],

    // Disable these temporarily, as they conflict with `unicorn/prefer-node-protocol`
    'import/no-unresolved': 'off',

    'node/no-unsupported-features/node-builtins': 'off',

    'node/no-missing-import': 'off',
  },
}
