Skip to content
Snippets Groups Projects
.eslintrc.js 1.13 KiB
Newer Older
Hugo SUBTIL's avatar
Hugo SUBTIL committed
module.exports = {
  parser: '@typescript-eslint/parser',
  parserOptions: {
    project: true,
Hugo SUBTIL's avatar
Hugo SUBTIL committed
    sourceType: 'module',
  },
  plugins: ['@typescript-eslint/eslint-plugin', 'jest', 'jsdoc', 'regexp'],
  extends: [
    'plugin:@typescript-eslint/recommended',
    'plugin:prettier/recommended',
    'plugin:jest/recommended',
    'plugin:regexp/recommended',
Hugo SUBTIL's avatar
Hugo SUBTIL committed
  root: true,
  env: {
    node: true,
    jest: true,
  },
  rules: {
    '@typescript-eslint/interface-name-prefix': 'off',
    '@typescript-eslint/explicit-function-return-type': 'off',
    '@typescript-eslint/explicit-module-boundary-types': 'off',
Bastien DUMONT's avatar
Bastien DUMONT committed
    '@typescript-eslint/no-explicit-any': 'warn',

    'jest/no-conditional-expect': 'off',

    // JSDOC extends overrides: disable some of extends rules
    // JSdoc is not always needed
    'jsdoc/require-jsdoc': 0,
    // Prefer declaring types with typescript
    'jsdoc/require-returns': 0,
    'jsdoc/require-returns-type': 0,
    'jsdoc/require-param': 0,
    'jsdoc/require-param-type': 0,

    // Allow some params to be described and some to be omitted
    'jsdoc/check-param-names': 0,
Hugo SUBTIL's avatar
Hugo SUBTIL committed
  },
};