mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2024-12-27 05:52:47 +00:00
68fd375d95
Signed-off-by: David Mehren <git@herrmehren.de>
56 lines
1.3 KiB
JavaScript
56 lines
1.3 KiB
JavaScript
/* SPDX-FileCopyrightText: 2021 The HedgeDoc developers (see AUTHORS file)
|
|
*
|
|
* SPDX-License-Identifier: CC0-1.0
|
|
*/
|
|
module.exports = {
|
|
parser: '@typescript-eslint/parser',
|
|
parserOptions: {
|
|
project: 'tsconfig.json',
|
|
sourceType: 'module',
|
|
},
|
|
plugins: ['@typescript-eslint'],
|
|
extends: [
|
|
'eslint:recommended',
|
|
'plugin:@typescript-eslint/recommended',
|
|
'plugin:@typescript-eslint/recommended-requiring-type-checking',
|
|
'prettier',
|
|
],
|
|
root: true,
|
|
env: {
|
|
node: true,
|
|
jest: true,
|
|
},
|
|
rules: {
|
|
'@typescript-eslint/no-unused-vars': [
|
|
'warn',
|
|
{ argsIgnorePattern: '^_+$' },
|
|
],
|
|
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
|
'no-return-await': 'off',
|
|
'@typescript-eslint/return-await': ['error', 'always'],
|
|
'@typescript-eslint/naming-convention': [
|
|
'error',
|
|
{
|
|
selector: 'default',
|
|
format: ['camelCase'],
|
|
leadingUnderscore: 'allow',
|
|
trailingUnderscore: 'allow',
|
|
},
|
|
{
|
|
selector: 'enumMember',
|
|
format: ['UPPER_CASE'],
|
|
},
|
|
{
|
|
selector: 'variable',
|
|
format: ['camelCase', 'UPPER_CASE'],
|
|
leadingUnderscore: 'allow',
|
|
trailingUnderscore: 'allow',
|
|
},
|
|
|
|
{
|
|
selector: 'typeLike',
|
|
format: ['PascalCase'],
|
|
},
|
|
],
|
|
},
|
|
};
|