Skip to content

Commit d362f8b

Browse files
authored
Merge pull request #199 from Eyas/main
Update dev packages.
2 parents dea38ff + 22b10e1 commit d362f8b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+4532
-2782
lines changed

.eslintrc.cjs

Lines changed: 0 additions & 149 deletions
This file was deleted.

.github/workflows/ci.yml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,23 +13,20 @@ jobs:
1313

1414
strategy:
1515
matrix:
16-
node-version: [14.x, 16.x]
16+
node-version: [22.x, 23.x]
1717

1818
steps:
1919
- uses: actions/checkout@v2
2020
- name: Use Node.js ${{ matrix.node-version }}
2121
uses: actions/setup-node@v2
2222
with:
2323
node-version: ${{ matrix.node-version }}
24-
- name: Update NPM # Needed while 14.x, is supported.
25-
if: ${{ matrix.node-version == '14.x' }}
26-
run: npm install -g npm@latest
2724
- run: npm ci
2825
- run: npm run build
2926
- run: npm test
3027
- name: Coveralls - schema-dts-gen
3128
uses: coverallsapp/github-action@master
32-
if: ${{ matrix.node-version == '16.x' }}
29+
if: ${{ matrix.node-version == '22.x' }}
3330
with:
3431
github-token: ${{ secrets.GITHUB_TOKEN }}
3532
path-to-lcov: ./packages/schema-dts-gen/coverage/lcov.info

eslint.config.js

Lines changed: 165 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,165 @@
1+
import jsdoc from 'eslint-plugin-jsdoc';
2+
import importPlugin from 'eslint-plugin-import';
3+
import prettierConfig from 'eslint-config-prettier';
4+
import stylistic from '@stylistic/eslint-plugin';
5+
import tseslint from 'typescript-eslint';
6+
7+
export default tseslint.config(
8+
tseslint.configs.recommendedTypeChecked,
9+
prettierConfig,
10+
{
11+
languageOptions: {
12+
parserOptions: {
13+
projectService: true,
14+
tsconfigRootDir: [import.meta.dirname],
15+
},
16+
},
17+
},
18+
{
19+
files: ['**/*.ts'],
20+
plugins: {jsdoc, import: importPlugin, '@stylistic': stylistic},
21+
rules: {
22+
'@typescript-eslint/array-type': [
23+
'error',
24+
{
25+
default: 'array-simple',
26+
},
27+
],
28+
'@typescript-eslint/no-restricted-types': [
29+
'error',
30+
{
31+
types: {
32+
Object: {
33+
fixWith: 'object',
34+
},
35+
String: {
36+
fixWith: 'string',
37+
},
38+
Number: {
39+
fixWith: 'number',
40+
},
41+
Boolean: {
42+
fixWith: 'boolean',
43+
},
44+
},
45+
},
46+
],
47+
'@typescript-eslint/naming-convention': [
48+
'error',
49+
{
50+
selector: 'default',
51+
format: ['camelCase'],
52+
leadingUnderscore: 'allow',
53+
trailingUnderscore: 'allow',
54+
},
55+
{
56+
selector: 'variable',
57+
format: ['PascalCase', 'camelCase', 'UPPER_CASE'],
58+
modifiers: ['const'],
59+
leadingUnderscore: 'allow',
60+
trailingUnderscore: 'allow',
61+
},
62+
{
63+
selector: 'variableLike',
64+
format: ['PascalCase', 'camelCase'],
65+
filter: {regex: '^_$', match: false},
66+
},
67+
{
68+
selector: 'memberLike',
69+
format: ['camelCase', 'PascalCase'],
70+
},
71+
{
72+
selector: 'memberLike',
73+
modifiers: ['private'],
74+
format: ['camelCase', 'PascalCase'],
75+
leadingUnderscore: 'allow',
76+
},
77+
{
78+
selector: 'typeLike',
79+
format: ['PascalCase'],
80+
},
81+
{
82+
selector: ['typeProperty', 'objectLiteralProperty'],
83+
format: null,
84+
},
85+
],
86+
'@typescript-eslint/consistent-type-assertions': 'error',
87+
'@typescript-eslint/consistent-type-definitions': 'error',
88+
'@typescript-eslint/explicit-member-accessibility': [
89+
'error',
90+
{
91+
accessibility: 'no-public',
92+
},
93+
],
94+
'@stylistic/member-delimiter-style': [
95+
'error',
96+
{
97+
multiline: {
98+
delimiter: 'semi',
99+
requireLast: true,
100+
},
101+
singleline: {
102+
delimiter: 'semi',
103+
requireLast: false,
104+
},
105+
},
106+
],
107+
'@typescript-eslint/no-explicit-any': 'error',
108+
'@typescript-eslint/no-inferrable-types': 'error',
109+
'@typescript-eslint/no-namespace': 'error',
110+
'@typescript-eslint/no-require-imports': 'error',
111+
'@typescript-eslint/no-unused-expressions': [
112+
'error',
113+
{allowShortCircuit: true},
114+
],
115+
'@typescript-eslint/no-unused-vars': [
116+
'error',
117+
{
118+
argsIgnorePattern: '^_',
119+
caughtErrorsIgnorePattern: '^_',
120+
destructuredArrayIgnorePattern: '^_',
121+
varsIgnorePattern: '^_',
122+
ignoreRestSiblings: true,
123+
},
124+
],
125+
'@typescript-eslint/triple-slash-reference': 'error',
126+
'@stylistic/semi': ['error', 'always'],
127+
'arrow-body-style': 'error',
128+
curly: ['error', 'multi-line'],
129+
'default-case': 'error',
130+
eqeqeq: ['error', 'smart'],
131+
'guard-for-in': 'error',
132+
'id-denylist': [
133+
'error',
134+
'any',
135+
'Number',
136+
'number',
137+
'String',
138+
'string',
139+
'Boolean',
140+
'boolean',
141+
'Undefined',
142+
],
143+
'id-match': 'error',
144+
'import/no-default-export': 'error',
145+
'jsdoc/check-alignment': 'error',
146+
'new-parens': 'error',
147+
'no-debugger': 'error',
148+
'no-duplicate-case': 'error',
149+
'no-new-wrappers': 'error',
150+
'no-return-await': 'error',
151+
'no-throw-literal': 'error',
152+
'no-underscore-dangle': 'off',
153+
'no-unsafe-finally': 'error',
154+
'no-unused-expressions': ['error', {allowShortCircuit: true}],
155+
'no-unused-labels': 'error',
156+
'no-var': 'error',
157+
'object-shorthand': 'error',
158+
'prefer-arrow-callback': 'error',
159+
'prefer-const': 'error',
160+
radix: 'error',
161+
'use-isnan': 'error',
162+
},
163+
settings: {},
164+
},
165+
);

0 commit comments

Comments
 (0)