Skip to content

Commit 67930ea

Browse files
authored
Merge pull request #51 from bhaumikmaan/feat/github-workflows
Adding workflow configs
2 parents df5b653 + dee3f9b commit 67930ea

File tree

2 files changed

+56
-2
lines changed

2 files changed

+56
-2
lines changed

eslint.config.mjs

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
// eslint.config.mjs
2+
import js from "@eslint/js";
3+
import globals from "globals";
4+
import tseslint from "typescript-eslint";
5+
import json from "@eslint/json";
6+
import markdown from "@eslint/markdown";
7+
import css from "@eslint/css";
8+
9+
export default [
10+
js.configs.recommended,
11+
{
12+
files: ["**/*.{js,mjs,cjs,ts,tsx}"],
13+
languageOptions: {
14+
globals: {
15+
...globals.browser,
16+
...globals.node,
17+
},
18+
},
19+
},
20+
...tseslint.configs.recommended,
21+
{
22+
files: ["**/*.json"],
23+
plugins: { json },
24+
rules: { ...json.configs.recommended.rules }, // Spread the rules object
25+
},
26+
{
27+
files: ["**/*.jsonc"],
28+
plugins: { json },
29+
rules: { ...json.configs.recommended.rules }, // Spread the rules object
30+
},
31+
{
32+
files: ["**/*.json5"],
33+
plugins: { json },
34+
rules: { ...json.configs.recommended.rules }, // Spread the rules object
35+
},
36+
{
37+
files: ["**/*.md"],
38+
plugins: { markdown },
39+
rules: { ...markdown.configs.recommended.rules }, // Spread the rules object
40+
},
41+
{
42+
files: ["**/*.css"],
43+
plugins: { css },
44+
rules: { ...css.configs.recommended.rules }, // Spread the rules object
45+
},
46+
];

package.json

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
"scripts": {
66
"clean": "rimraf dist dist-electron",
77
"dev": "cross-env NODE_ENV=development npm run clean && concurrently \"tsc -w -p tsconfig.electron.json\" \"vite\" \"wait-on -t 30000 http://localhost:54321 && electron ./dist-electron/main.js\"",
8+
"test": "echo \"No tests defined. Please contribute if you like\" && exit 0",
9+
"lint": "npx eslint .",
810
"start": "cross-env NODE_ENV=development concurrently \"tsc -p tsconfig.electron.json\" \"vite\" \"wait-on -t 30000 http://localhost:54321 && electron ./dist-electron/main.js\"",
911
"build": "cross-env NODE_ENV=production rimraf dist dist-electron && vite build && tsc -p tsconfig.electron.json",
1012
"run-prod": "cross-env NODE_ENV=production electron ./dist-electron/main.js",
@@ -152,6 +154,10 @@
152154
},
153155
"devDependencies": {
154156
"@electron/typescript-definitions": "^8.14.0",
157+
"@eslint/css": "^0.6.0",
158+
"@eslint/js": "^9.24.0",
159+
"@eslint/json": "^0.11.0",
160+
"@eslint/markdown": "^6.3.0",
155161
"@types/color": "^4.2.0",
156162
"@types/diff": "^6.0.0",
157163
"@types/electron-store": "^1.3.1",
@@ -170,9 +176,11 @@
170176
"electron": "^29.1.4",
171177
"electron-builder": "^24.13.3",
172178
"electron-is-dev": "^3.0.1",
173-
"eslint": "^8.57.0",
179+
"eslint": "^8.57.1",
180+
"eslint-flat-config-utils": "^2.0.1",
174181
"eslint-plugin-react-hooks": "^4.6.0",
175182
"eslint-plugin-react-refresh": "^0.4.6",
183+
"globals": "^16.0.0",
176184
"postcss": "^8.4.49",
177185
"rimraf": "^6.0.1",
178186
"tailwindcss": "^3.4.15",
@@ -194,4 +202,4 @@
194202
"last 1 safari version"
195203
]
196204
}
197-
}
205+
}

0 commit comments

Comments
 (0)