mirror of
https://github.com/documenso/documenso.git
synced 2025-11-10 04:22:32 +10:00
61 lines
1.5 KiB
JavaScript
61 lines
1.5 KiB
JavaScript
module.exports = {
|
|
extends: [
|
|
'next',
|
|
'turbo',
|
|
'prettier',
|
|
'eslint:recommended',
|
|
'plugin:@typescript-eslint/recommended',
|
|
'plugin:prettier/recommended',
|
|
'plugin:package-json/recommended',
|
|
'plugin:import/recommended',
|
|
],
|
|
|
|
plugins: ['prettier', 'package-json', 'import', 'simple-import-sort'],
|
|
|
|
env: {
|
|
node: true,
|
|
browser: true,
|
|
es6: true,
|
|
},
|
|
|
|
parser: '@typescript-eslint/parser',
|
|
|
|
parserOptions: {
|
|
ecmaVersion: 2022,
|
|
ecmaFeatures: {
|
|
jsx: true,
|
|
},
|
|
sourceType: 'module',
|
|
},
|
|
|
|
rules: {
|
|
'react/no-unescaped-entities': 'off',
|
|
|
|
'no-unused-vars': ['error', { argsIgnorePattern: '^_' }],
|
|
'@typescript-eslint/no-unused-vars': ['error', { argsIgnorePattern: '^_' }],
|
|
|
|
// We never want to use `as` but are required to on occasion to handle
|
|
// shortcomings in third-party and generated types.
|
|
//
|
|
// To handle this we want this rule to catch usages and highlight them as
|
|
// warnings so we can write appropriate interfaces and guards later.
|
|
'@typescript-eslint/consistent-type-assertions': ['warn', { assertionStyle: 'never' }],
|
|
'no-multi-spaces': [
|
|
'error',
|
|
{
|
|
ignoreEOLComments: false,
|
|
exceptions: {
|
|
BinaryExpression: false,
|
|
VariableDeclarator: false,
|
|
ImportDeclaration: false,
|
|
Property: false,
|
|
},
|
|
},
|
|
],
|
|
'import/named': 'error',
|
|
'import/no-named-as-default': 'off',
|
|
'import/namespace': 'off',
|
|
'no-duplicate-imports': 'error',
|
|
},
|
|
};
|