@pixelplex/mail-service 0.2.7 → 0.2.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/eslint.config.js DELETED
@@ -1,128 +0,0 @@
1
- const path = require('path');
2
- const tsParser = require('@typescript-eslint/parser');
3
- const tsPlugin = require('@typescript-eslint/eslint-plugin');
4
- const prettierPlugin = require('eslint-plugin-prettier');
5
- const stylisticTs = require('@stylistic/eslint-plugin');
6
- const importPlugin = require('eslint-plugin-import');
7
- const { defineFlatConfig } = require('eslint-define-config');
8
-
9
- module.exports = defineFlatConfig([
10
- {
11
- ignores: ['node_modules', 'dist'],
12
- },
13
- {
14
- files: ['**/*.{ts,tsx}'],
15
- languageOptions: {
16
- parser: tsParser,
17
- parserOptions: {
18
- project: path.resolve(__dirname, 'tsconfig.json'),
19
- sourceType: 'module',
20
- },
21
- },
22
- plugins: {
23
- '@typescript-eslint': tsPlugin,
24
- prettier: prettierPlugin,
25
- '@stylistic': stylisticTs,
26
- import: importPlugin,
27
- },
28
- rules: {
29
- // Code style
30
- 'brace-style': ['error', '1tbs'],
31
- curly: ['error', 'all'],
32
- quotes: ['error', 'single'],
33
- semi: 'off',
34
- 'space-before-blocks': 'error',
35
- 'object-curly-spacing': ['error', 'always'],
36
- 'eol-last': ['error', 'always'],
37
- 'no-tabs': 'error',
38
- 'no-trailing-spaces': 'error',
39
- 'no-multiple-empty-lines': ['error', { max: 1 }],
40
- 'key-spacing': 'error',
41
- 'keyword-spacing': 'error',
42
- 'arrow-spacing': ['error', { before: true, after: true }],
43
- 'object-shorthand': ['error', 'always'],
44
-
45
- // Import linting
46
- 'import/no-named-as-default': 'off',
47
- 'import/no-named-as-default-member': 'off',
48
- 'import/order': [
49
- 'error',
50
- {
51
- groups: ['builtin', 'external', 'internal', 'parent', 'sibling', 'index'],
52
- 'newlines-between': 'always',
53
- alphabetize: {
54
- order: 'asc',
55
- caseInsensitive: true,
56
- },
57
- pathGroups: [
58
- {
59
- pattern: '@{apps|libs|pixelplex|modules}/**',
60
- group: 'internal',
61
- position: 'after',
62
- },
63
- ],
64
- },
65
- ],
66
-
67
- // Prettier
68
- 'prettier/prettier': 'error',
69
-
70
- // Business logic errors
71
- 'no-console': 'error',
72
- 'no-loop-func': 'error',
73
- 'no-magic-numbers': [
74
- 'error',
75
- {
76
- ignore: [0, 1, 2, 3, 4, 5, 10, 60, 1000],
77
- ignoreArrayIndexes: true,
78
- enforceConst: true,
79
- detectObjects: false,
80
- },
81
- ],
82
- 'no-unused-expressions': ['error', { allowShortCircuit: true, allowTernary: true }],
83
- 'no-unsafe-optional-chaining': 'error',
84
- 'no-return-await': 'error',
85
- 'prefer-const': 'error',
86
-
87
- // TypeScript specific
88
- '@typescript-eslint/prefer-readonly': 'error',
89
- '@typescript-eslint/prefer-for-of': 'error',
90
- '@typescript-eslint/prefer-literal-enum-member': 'error',
91
- '@typescript-eslint/promise-function-async': 'error',
92
- '@typescript-eslint/no-misused-promises': 'error',
93
- '@typescript-eslint/no-loop-func': 'error',
94
- '@typescript-eslint/no-unnecessary-type-constraint': 'error',
95
- '@typescript-eslint/require-await': 'error',
96
- '@typescript-eslint/no-unused-vars': ['error', { ignoreRestSiblings: true }],
97
- '@typescript-eslint/no-use-before-define': [
98
- 'error',
99
- { functions: false, classes: false, variables: true, typedefs: true },
100
- ],
101
- '@stylistic/no-explicit-any': 'off',
102
- '@stylistic/no-inferrable-types': 'off',
103
- '@stylistic/member-delimiter-style': [
104
- 'error',
105
- {
106
- multiline: { delimiter: 'semi', requireLast: true },
107
- singleline: { delimiter: 'semi', requireLast: false },
108
- },
109
- ],
110
- '@stylistic/type-annotation-spacing': 'error',
111
-
112
- // Custom rules (@/)
113
- '@/comma-dangle': ['error', 'always-multiline'],
114
- '@/semi': ['error'],
115
-
116
- // Additional rules
117
- '@stylistic/padding-line-between-statements': [
118
- 'error',
119
- { blankLine: 'always', prev: '*', next: 'return' },
120
- { blankLine: 'always', prev: '*', next: 'continue' },
121
- { blankLine: 'always', prev: '*', next: ['if', 'for', 'switch', 'while'] },
122
- { blankLine: 'always', prev: ['if', 'for', 'switch', 'while'], next: '*' },
123
- { blankLine: 'always', prev: 'import', next: '*' },
124
- { blankLine: 'any', prev: 'import', next: 'import' },
125
- ],
126
- },
127
- },
128
- ]);