UNPKG

1.57 kBJavaScriptView Raw
1module.exports = {
2 root: true,
3 parser: '@typescript-eslint/parser',
4 extends: ['plugin:node/recommended', 'plugin:prettier/recommended'],
5 parserOptions: {
6 ecmaVersion: 2018,
7 sourceType: 'module',
8 },
9 settings: {
10 node: {
11 tryExtensions: ['.js', '.json', '.ts', '.d.ts'],
12 },
13 },
14 rules: {
15 // 'no-process-exit': 'off', // to investigate if we should throw an error instead of process.exit()
16 // 'node/no-unsupported-features/es-builtins': 'off',
17 },
18 overrides: [
19 {
20 files: ['*.ts'],
21 extends: [
22 'plugin:@typescript-eslint/recommended', // Uses the recommended rules from the @typescript-eslint/eslint-plugin
23 'prettier/@typescript-eslint', // Uses eslint-config-prettier to disable ESLint rules from @typescript-eslint/eslint-plugin that would conflict with prettier
24 'plugin:prettier/recommended', // Enables eslint-plugin-prettier and eslint-config-prettier. This will display prettier errors as ESLint errors. Make sure this is always the last configuration in the extends array.
25 ],
26 rules: {
27 'node/no-unsupported-features/es-syntax': 'off',
28 '@typescript-eslint/explicit-module-boundary-types': 'off',
29 '@typescript-eslint/no-non-null-assertion': 'off',
30 '@typescript-eslint/no-explicit-any': 'off',
31 '@typescript-eslint/no-unused-vars': 'off',
32 // '@typescript-eslint/explicit-function-return-type': 'off',
33 // '@typescript-eslint/no-namespace': 'off' // maybe we should consider enabling it in the future
34 },
35 },
36 ],
37};