Skip to content

Commit

Permalink
add eslint & CI
Browse files Browse the repository at this point in the history
  • Loading branch information
hyperneutrino committed Jul 16, 2024
1 parent 250dced commit f0f3f62
Show file tree
Hide file tree
Showing 4 changed files with 1,058 additions and 6,336 deletions.
15 changes: 15 additions & 0 deletions .github/workflows/eslint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: ESLint
on:
pull_request:
jobs:
eslint:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
- name: Install modules
run: pnpm install --frozen-lockfile
- name: ESLint Action
run: eslint
18 changes: 18 additions & 0 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
import pluginJs from "@eslint/js";
import eslintPluginSvelte from "eslint-plugin-svelte";
import globals from "globals";
import tseslint from "typescript-eslint";

export default [
...eslintPluginSvelte.configs["flat/recommended"],
{
files: ["apps/**/*.*", "packages/**/*.*"],
},
{
languageOptions: {
globals: globals.browser,
},
},
pluginJs.configs.recommended,
...tseslint.configs.recommended,
];
8 changes: 7 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,15 @@
"prepare": "husky install"
},
"devDependencies": {
"@eslint/js": "^9.7.0",
"eslint": "~9.7.0",
"eslint-plugin-svelte": "^2.42.0",
"globals": "^15.8.0",
"prettier": "^3.2.5",
"svelte": "^4.2.18",
"turbo": "^2.0.6",
"typescript": "^5.4.5"
"typescript": "^5.4.5",
"typescript-eslint": "^7.16.1"
},
"packageManager": "[email protected]",
"engines": {
Expand Down
Loading

0 comments on commit f0f3f62

Please sign in to comment.