@fullstacksjs/eslint-config 11.1.13 → 11.1.14
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/package.json +1 -1
- package/src/index.js +1 -1
- package/src/modules/base.js +1 -1
- package/src/modules/imports.js +1 -1
- package/src/modules/jest.js +1 -1
- package/src/modules/node.js +1 -1
- package/src/modules/prettier.js +1 -1
- package/src/modules/tests.js +1 -1
- package/src/modules/typescript.js +1 -1
- package/src/modules/esm.js +0 -14
- package/src/modules/graphql.js +0 -85
- /package/src/{option.ts → option.d.ts} +0 -0
package/package.json
CHANGED
package/src/index.js
CHANGED
|
@@ -21,7 +21,7 @@ import { compose } from './utils/compose.js';
|
|
|
21
21
|
|
|
22
22
|
const testPackages = ['jest', 'vitest', 'cypress', 'playwright'];
|
|
23
23
|
|
|
24
|
-
/** @type {import('./option.
|
|
24
|
+
/** @type {import('./option.d.ts').Options} */
|
|
25
25
|
const defaultOptions = {
|
|
26
26
|
cypress: isPackageExists('cypress'),
|
|
27
27
|
disableExpensiveRules: false,
|
package/src/modules/base.js
CHANGED
|
@@ -3,7 +3,7 @@ import globals from 'globals';
|
|
|
3
3
|
import { strict } from '../utils/conditions.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* @param {
|
|
6
|
+
* @param { import('../option.d.ts').Options } options
|
|
7
7
|
* @return { import('eslint').Linter.Config }
|
|
8
8
|
*/
|
|
9
9
|
function base(options = {}) {
|
package/src/modules/imports.js
CHANGED
|
@@ -7,7 +7,7 @@ const jsExtensions = ['.mjs', '.js', '.jsx', '.cjs'];
|
|
|
7
7
|
const allExtensions = [...jsExtensions, ...tsExtensions];
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
|
-
* @param { import('../option').Options } options
|
|
10
|
+
* @param { import('../option.d.ts').Options } options
|
|
11
11
|
* @return { import('eslint').Linter.Config }
|
|
12
12
|
*/
|
|
13
13
|
function imports(options = {}) {
|
package/src/modules/jest.js
CHANGED
|
@@ -3,7 +3,7 @@ import plugin from 'eslint-plugin-jest';
|
|
|
3
3
|
import { globs } from '../utils/globs.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* @param { import('../option').Options } options
|
|
6
|
+
* @param { import('../option.d.ts').Options } options
|
|
7
7
|
* @return { import('eslint').Linter.Config } */
|
|
8
8
|
function jest() {
|
|
9
9
|
return {
|
package/src/modules/node.js
CHANGED
|
@@ -3,7 +3,7 @@ import plugin from 'eslint-plugin-n';
|
|
|
3
3
|
import { strict } from '../utils/conditions.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
|
-
* @param { import('../option').Options } options
|
|
6
|
+
* @param { import('../option.d.ts').Options } options
|
|
7
7
|
* @return { import('eslint').Linter.Config }
|
|
8
8
|
*/
|
|
9
9
|
function node(options = {}) {
|
package/src/modules/prettier.js
CHANGED
package/src/modules/tests.js
CHANGED
|
@@ -5,7 +5,7 @@ import { predicate } from '../utils/conditions.js';
|
|
|
5
5
|
import { globs } from '../utils/globs.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
|
-
* @param { import('../option').Options } options
|
|
8
|
+
* @param { import('../option.d.ts').Options } options
|
|
9
9
|
* @return { import('eslint').Linter.Config }
|
|
10
10
|
*/
|
|
11
11
|
function tests(options = {}) {
|
|
@@ -5,7 +5,7 @@ import { globs } from '../utils/globs.js';
|
|
|
5
5
|
import { namingConvention } from '../utils/naming-convention.js';
|
|
6
6
|
|
|
7
7
|
/**
|
|
8
|
-
* @param { import('../option').Options } options
|
|
8
|
+
* @param { import('../option.d.ts').Options } options
|
|
9
9
|
* @return { import('eslint').Linter.Config }
|
|
10
10
|
*/
|
|
11
11
|
function typescript(options = {}) {
|
package/src/modules/esm.js
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
/** @type { import('eslint').Linter.Config } */
|
|
2
|
-
module.exports = {
|
|
3
|
-
rules: {
|
|
4
|
-
...(global.fullstacksjs?.import && { 'import/extensions': ['error', { mjs: 'ignorePackages' }] }),
|
|
5
|
-
},
|
|
6
|
-
overrides: [
|
|
7
|
-
{
|
|
8
|
-
files: ['*.ts', '*.tsx'],
|
|
9
|
-
rules: {
|
|
10
|
-
...(global.fullstacksjs?.import && { 'import/no-unresolved': ['error', { ignore: ['.js$'], caseSensitiveStrict: true }] }),
|
|
11
|
-
},
|
|
12
|
-
},
|
|
13
|
-
],
|
|
14
|
-
};
|
package/src/modules/graphql.js
DELETED
|
@@ -1,85 +0,0 @@
|
|
|
1
|
-
import plugin, { configs } from '@graphql-eslint/eslint-plugin';
|
|
2
|
-
|
|
3
|
-
import { globs } from '../utils/globs.js';
|
|
4
|
-
|
|
5
|
-
configs['schema-recommended'].parser;
|
|
6
|
-
|
|
7
|
-
/** @return { import('eslint').Linter.Config } */
|
|
8
|
-
function graphql() {
|
|
9
|
-
return {
|
|
10
|
-
files: globs.graphql,
|
|
11
|
-
plugins: { graphql: plugin },
|
|
12
|
-
languageOptions: {
|
|
13
|
-
parser: configs['schema-recommended'].parser,
|
|
14
|
-
},
|
|
15
|
-
rules: {
|
|
16
|
-
'@graphql-eslint/alphabetize': ['warn', { fields: ['ObjectTypeDefinition'] }],
|
|
17
|
-
'@graphql-eslint/description-style': 'warn',
|
|
18
|
-
'@graphql-eslint/executable-definitions': 'off',
|
|
19
|
-
'@graphql-eslint/fields-on-correct-type': 'warn',
|
|
20
|
-
'@graphql-eslint/fragments-on-composite-type': 'warn',
|
|
21
|
-
'@graphql-eslint/input-name': 'warn',
|
|
22
|
-
'@graphql-eslint/known-argument-names': 'warn',
|
|
23
|
-
'@graphql-eslint/known-directives': 'warn',
|
|
24
|
-
'@graphql-eslint/known-fragment-names': 'warn',
|
|
25
|
-
'@graphql-eslint/known-type-names': 'warn',
|
|
26
|
-
'@graphql-eslint/lone-anonymous-operation': 'warn',
|
|
27
|
-
'@graphql-eslint/lone-executable-definition': 'off',
|
|
28
|
-
'@graphql-eslint/lone-schema-definition': 'warn',
|
|
29
|
-
'@graphql-eslint/match-document-filename': ['warn', { query: 'camelCase', mutation: 'camelCase', subscription: 'camelCase' }],
|
|
30
|
-
'@graphql-eslint/naming-convention': 'warn',
|
|
31
|
-
'@graphql-eslint/no-anonymous-operations': 'warn',
|
|
32
|
-
'@graphql-eslint/no-case-insensitive-enum-values-duplicates': 'warn',
|
|
33
|
-
'@graphql-eslint/no-deprecated': 'warn',
|
|
34
|
-
'@graphql-eslint/no-duplicate-fields': 'warn',
|
|
35
|
-
'@graphql-eslint/no-fragment-cycles': 'warn',
|
|
36
|
-
'@graphql-eslint/no-hashtag-description': 'warn',
|
|
37
|
-
'@graphql-eslint/no-one-place-fragments': 'off',
|
|
38
|
-
'@graphql-eslint/no-root-type': 'off',
|
|
39
|
-
'@graphql-eslint/no-scalar-result-type-on-mutation': 'warn',
|
|
40
|
-
'@graphql-eslint/no-typename-prefix': 'warn',
|
|
41
|
-
'@graphql-eslint/no-undefined-variables': 'warn',
|
|
42
|
-
'@graphql-eslint/no-unreachable-types': 'warn',
|
|
43
|
-
'@graphql-eslint/no-unused-fields': 'warn',
|
|
44
|
-
'@graphql-eslint/no-unused-fragments': 'warn',
|
|
45
|
-
'@graphql-eslint/no-unused-variables': 'warn',
|
|
46
|
-
'@graphql-eslint/one-field-subscriptions': 'warn',
|
|
47
|
-
'@graphql-eslint/overlapping-fields-can-be-merged': 'warn',
|
|
48
|
-
'@graphql-eslint/possible-fragment-spread': 'warn',
|
|
49
|
-
'@graphql-eslint/possible-type-extension': 'warn',
|
|
50
|
-
'@graphql-eslint/provided-required-arguments': 'warn',
|
|
51
|
-
'@graphql-eslint/relay-arguments': 'warn',
|
|
52
|
-
'@graphql-eslint/relay-connection-types': 'warn',
|
|
53
|
-
'@graphql-eslint/relay-edge-types': 'warn',
|
|
54
|
-
'@graphql-eslint/relay-page-info': 'warn',
|
|
55
|
-
'@graphql-eslint/require-deprecation-date': 'warn',
|
|
56
|
-
'@graphql-eslint/require-deprecation-reason': 'warn',
|
|
57
|
-
'@graphql-eslint/require-description': 'off',
|
|
58
|
-
'@graphql-eslint/require-field-of-type-query-in-mutation-result': 'warn',
|
|
59
|
-
'@graphql-eslint/require-id-when-available': 'warn',
|
|
60
|
-
'@graphql-eslint/require-import-fragment': 'off',
|
|
61
|
-
'@graphql-eslint/require-nullable-fields-with-oneof': 'warn',
|
|
62
|
-
'@graphql-eslint/require-nullable-result-in-root': 'off',
|
|
63
|
-
'@graphql-eslint/require-type-pattern-with-oneof': 'warn',
|
|
64
|
-
'@graphql-eslint/scalar-leafs': 'warn',
|
|
65
|
-
'@graphql-eslint/selection-set-depth': 'off',
|
|
66
|
-
'@graphql-eslint/strict-id-in-types': 'warn',
|
|
67
|
-
'@graphql-eslint/unique-argument-names': 'warn',
|
|
68
|
-
'@graphql-eslint/unique-directive-names-per-location': 'warn',
|
|
69
|
-
'@graphql-eslint/unique-directive-names': 'warn',
|
|
70
|
-
'@graphql-eslint/unique-enum-value-names': 'warn',
|
|
71
|
-
'@graphql-eslint/unique-field-definition-names': 'warn',
|
|
72
|
-
'@graphql-eslint/unique-fragment-name': 'warn',
|
|
73
|
-
'@graphql-eslint/unique-input-field-names': 'warn',
|
|
74
|
-
'@graphql-eslint/unique-operation-name': 'warn',
|
|
75
|
-
'@graphql-eslint/unique-operation-types': 'warn',
|
|
76
|
-
'@graphql-eslint/unique-type-names': 'warn',
|
|
77
|
-
'@graphql-eslint/unique-variable-names': 'warn',
|
|
78
|
-
'@graphql-eslint/value-literals-of-correct-type': 'warn',
|
|
79
|
-
'@graphql-eslint/variables-are-input-types': 'warn',
|
|
80
|
-
'@graphql-eslint/variables-in-allowed-position': 'warn',
|
|
81
|
-
},
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
export default graphql;
|
|
File without changes
|