Skip to content

Commit a313b8d

Browse files
committed
fix: fix lint warnings
1 parent 6b0e13b commit a313b8d

File tree

5 files changed

+9
-7
lines changed

5 files changed

+9
-7
lines changed

.prettierignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,5 @@ tailwind.config.cjs
3232
tsconfig.json
3333
.pnpm-store
3434
src/i18n
35-
.devcontainer/devcontainer.json
35+
.devcontainer/devcontainer.json
36+
.vscode/

eslint.config.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ const rules = {
3434
caughtErrorsIgnorePattern: '^_',
3535
}
3636
],
37-
'@typescript-eslint/no-unused-expressions': 'warn',
37+
// TODO: This was disabled to due the explicit side-effect style in svelte (`$: ...`). Can be re-enabled with runes
38+
'@typescript-eslint/no-unused-expressions': 'off',
3839
'svelte/no-at-html-tags': 'warn',
3940
};
4041

src/lib/components/mods/compatibility/CompatibilityGrid.svelte

+2-2
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
<span style="padding: 2px; white-space:normal">
6262
{#if compatibility?.EA?.note}
6363
{#await markdown(compatibility.EA.note) then rendered}
64-
{@html rendered}
64+
{@html rendered} <!-- eslint-disable-line svelte/no-at-html-tags -->
6565
{/await}
6666
{:else}
6767
{noNotesText}
@@ -72,7 +72,7 @@
7272
<span style="padding: 2px; white-space:normal">
7373
{#if compatibility?.EXP?.note}
7474
{#await markdown(compatibility.EXP.note) then rendered}
75-
{@html rendered}
75+
{@html rendered} <!-- eslint-disable-line svelte/no-at-html-tags -->
7676
{/await}
7777
{:else}
7878
{noNotesText}

src/lib/utils/mod.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ export const modStatus = (latestVersions?: {
2222
}
2323
result = 'own-risk';
2424
}
25-
} catch (e) {
25+
} catch (_e) {
2626
// Ignored
2727
}
2828
}

src/lib/utils/uplugin.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const resolveValue = (object: unknown, path: string) => {
1919
key = parser.exec(path);
2020
}
2121
return value;
22-
} catch (e) {
22+
} catch (_e) {
2323
// Ignore exception
2424
}
2525

@@ -56,7 +56,7 @@ export const validateUPluginJson = async (input: string): Promise<string[]> => {
5656
return message;
5757
})
5858
.filter((v) => !!v);
59-
} catch (e) {
59+
} catch (_e) {
6060
return ['Invalid JSON'];
6161
}
6262
};

0 commit comments

Comments
 (0)