@keragon/connector-cli 0.0.12 → 0.0.13

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.
@@ -0,0 +1,124 @@
1
+ import js from '@eslint/js';
2
+ import typescript from '@typescript-eslint/eslint-plugin';
3
+ import typescriptParser from '@typescript-eslint/parser';
4
+ import jsoncParser from 'jsonc-eslint-parser';
5
+ import jsonc from 'eslint-plugin-jsonc';
6
+
7
+ export default [
8
+ // Base configuration for all files
9
+ js.configs.recommended,
10
+
11
+ // Global ignore patterns
12
+ {
13
+ ignores: [
14
+ 'dist/',
15
+ 'node_modules/',
16
+ '*.d.ts',
17
+ 'coverage/'
18
+ ]
19
+ },
20
+
21
+ // TypeScript and JavaScript configuration
22
+ {
23
+ files: ['**/*.ts', '**/*.tsx', '**/*.js', '**/*.jsx'],
24
+ languageOptions: {
25
+ parser: typescriptParser,
26
+ parserOptions: {
27
+ ecmaVersion: 'latest',
28
+ sourceType: 'module'
29
+ },
30
+ globals: {
31
+ // Node.js globals
32
+ process: 'readonly',
33
+ __dirname: 'readonly',
34
+ __filename: 'readonly',
35
+ global: 'readonly',
36
+ Buffer: 'readonly',
37
+ console: 'readonly',
38
+ setTimeout: 'readonly',
39
+ clearTimeout: 'readonly',
40
+ setInterval: 'readonly',
41
+ clearInterval: 'readonly',
42
+ setImmediate: 'readonly',
43
+ clearImmediate: 'readonly',
44
+ // Web API globals
45
+ URL: 'readonly'
46
+ }
47
+ },
48
+ plugins: {
49
+ '@typescript-eslint': typescript
50
+ },
51
+ rules: {
52
+ '@typescript-eslint/no-unused-vars': [
53
+ 'error',
54
+ {
55
+ argsIgnorePattern: '^_',
56
+ varsIgnorePattern: '^_'
57
+ }
58
+ ],
59
+ 'no-console': 'error',
60
+ 'no-debugger': 'error',
61
+ 'prefer-const': 'error',
62
+ 'no-var': 'error',
63
+ 'no-extra-semi': 'error',
64
+ quotes: ['warn', 'single', { avoidEscape: true }],
65
+ 'indent': ['error', 2]
66
+ }
67
+ },
68
+
69
+ // Test files configuration
70
+ {
71
+ files: ['**/*.spec.ts', '**/*.spec.tsx', '**/*.test.ts', '**/*.test.tsx', '**/*.spec.js', '**/*.spec.jsx', '**/*.test.js', '**/*.test.jsx'],
72
+ languageOptions: {
73
+ globals: {
74
+ // Jest globals
75
+ jest: 'readonly',
76
+ describe: 'readonly',
77
+ it: 'readonly',
78
+ test: 'readonly',
79
+ expect: 'readonly',
80
+ beforeEach: 'readonly',
81
+ afterEach: 'readonly',
82
+ beforeAll: 'readonly',
83
+ afterAll: 'readonly',
84
+ xdescribe: 'readonly',
85
+ xit: 'readonly',
86
+ xtest: 'readonly',
87
+ fit: 'readonly',
88
+ fdescribe: 'readonly'
89
+ }
90
+ },
91
+ rules: {
92
+ 'no-console': 'warn'
93
+ }
94
+ },
95
+
96
+ // Jest config files
97
+ {
98
+ files: ['**/jest.config.ts'],
99
+ languageOptions: {
100
+ globals: {
101
+ module: 'readonly'
102
+ }
103
+ }
104
+ },
105
+
106
+ // JSON files configuration using jsonc-eslint-parser
107
+ {
108
+ files: ['**/*.json'],
109
+ languageOptions: {
110
+ parser: jsoncParser
111
+ },
112
+ plugins: {
113
+ jsonc: jsonc
114
+ },
115
+ rules: {
116
+ 'jsonc/no-dupe-keys': 'error',
117
+ 'jsonc/no-comments': 'error',
118
+ 'jsonc/comma-dangle': ['error', 'never'],
119
+ 'jsonc/indent': ['error', 2],
120
+ 'jsonc/quotes': ['error', 'double'],
121
+ 'jsonc/quote-props': ['error', 'always']
122
+ }
123
+ }
124
+ ];
@@ -0,0 +1,6 @@
1
+ export default {
2
+ preset: 'ts-jest',
3
+ testEnvironment: 'node',
4
+ coverageReporters: ['lcov'],
5
+ clearMocks: true,
6
+ };
@@ -9,16 +9,23 @@
9
9
  },
10
10
  "author": "",
11
11
  "license": "ISC",
12
+ "scripts": {
13
+ "test": "jest --passWithNoTests"
14
+ },
12
15
  "dependencies": {
13
- "@keragon/connector-sdk": "^0.0.3"
16
+ "@keragon/connector-sdk": "^0.0.4"
14
17
  },
15
18
  "devDependencies": {
16
- "jest": "^29.7.0",
17
- "@typescript-eslint/parser": "7.18.0",
18
- "@typescript-eslint/eslint-plugin": "7.18.0",
19
- "eslint": "8.57.1",
20
- "typescript": "^5.0.0",
21
- "jsonc-eslint-parser": "^2.1.0",
19
+ "jest": "^30.0.5",
20
+ "ts-jest": "^29.4.1",
21
+ "ts-node": "^10.9.2",
22
+ "@types/jest": "^30.0.0",
23
+ "@eslint/js": "^9.32.0",
24
+ "@typescript-eslint/parser": "^8.39.0",
25
+ "@typescript-eslint/eslint-plugin": "^8.39.0",
26
+ "eslint": "^9.32.0",
27
+ "typescript": "5.6.0",
28
+ "jsonc-eslint-parser": "^2.4.0",
22
29
  "eslint-plugin-jsonc": "^2.20.1"
23
30
  }
24
31
  }