Skip to content

Commit 2b52eaf

Browse files
committed
clean up
1 parent 7e7d57d commit 2b52eaf

6 files changed

Lines changed: 49 additions & 81 deletions

File tree

.github/workflows/build_android.yml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,6 @@ jobs:
2222
working-directory: ./frontend
2323
run: npm install
2424

25-
- name: Prepare wasm
26-
working-directory: ./frontend
27-
run: |
28-
chmod +x scripts/setup.sh
29-
./scripts/setup.sh
30-
3125
- name: Setup Java
3226
uses: actions/setup-java@v4
3327
with:

.github/workflows/build_frontend.yml

Lines changed: 16 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -11,30 +11,25 @@ on:
1111

1212
jobs:
1313
build:
14-
1514
runs-on: ubuntu-latest
1615
defaults:
1716
run:
1817
working-directory: ./frontend
1918

2019
steps:
21-
- uses: actions/checkout@v4
22-
- name: Install Node.js
23-
uses: actions/setup-node@v4
24-
- name: Prepare wasm
25-
run: |
26-
chmod +x scripts/setup.sh
27-
./scripts/setup.sh
28-
- name: Install Dependencies
29-
run: npm install
30-
- name: Build
31-
run: npm run build
32-
- name: Lint
33-
run: npm run lint
34-
- name: Run tests
35-
run: npm run test
36-
- name: Upload artifact
37-
if: ${{ inputs.upload }}
38-
uses: actions/upload-pages-artifact@v3
39-
with:
40-
path: './frontend/build'
20+
- uses: actions/checkout@v4
21+
- name: Install Node.js
22+
uses: actions/setup-node@v4
23+
- name: Install Dependencies
24+
run: npm install
25+
- name: Build
26+
run: npm run build
27+
- name: Lint
28+
run: npm run lint
29+
- name: Run tests
30+
run: npm run test
31+
- name: Upload artifact
32+
if: ${{ inputs.upload }}
33+
uses: actions/upload-pages-artifact@v3
34+
with:
35+
path: "./frontend/build"

frontend/eslint.config.js

Lines changed: 33 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,37 @@
1-
import js from '@eslint/js';
2-
import { includeIgnoreFile } from '@eslint/compat';
3-
import svelte from 'eslint-plugin-svelte';
4-
import globals from 'globals';
5-
import { fileURLToPath } from 'node:url';
6-
import ts from 'typescript-eslint';
7-
import svelteConfig from './svelte.config.js';
1+
import js from "@eslint/js";
2+
import { includeIgnoreFile } from "@eslint/compat";
3+
import svelte from "eslint-plugin-svelte";
4+
import { fileURLToPath } from "node:url";
5+
import ts from "typescript-eslint";
6+
import svelteConfig from "./svelte.config.js";
87

9-
const gitignorePath = fileURLToPath(new URL('./.gitignore', import.meta.url));
8+
const gitignorePath = fileURLToPath(new URL("./.gitignore", import.meta.url));
109

1110
export default ts.config(
12-
includeIgnoreFile(gitignorePath),
13-
js.configs.recommended,
14-
...ts.configs.strict,
15-
...svelte.configs.recommended,
16-
{
17-
languageOptions: {
18-
globals: { ...globals.browser, ...globals.node }
19-
},
20-
rules: { // typescript-eslint strongly recommend that you do not use the no-undef lint rule on TypeScript projects.
21-
// see: https://typescript-eslint.io/troubleshooting/faqs/eslint/#i-get-errors-from-the-no-undef-rule-about-global-variables-not-being-defined-even-though-there-are-no-typescript-errors
22-
"no-undef": 'off',
23-
}
24-
},
25-
{
26-
// Note: there should be no other properties in this object
27-
ignores: ["wasm-lib/*", "dev-dist/*", "coverage/*"],
28-
},
29-
{
30-
files: [
31-
'**/*.svelte',
32-
'**/*.svelte.ts',
33-
'**/*.svelte.js'
34-
],
35-
languageOptions: {
36-
parserOptions: {
37-
projectService: true,
38-
extraFileExtensions: ['.svelte'],
39-
parser: ts.parser,
40-
svelteConfig
41-
}
42-
}
43-
}
11+
includeIgnoreFile(gitignorePath),
12+
js.configs.recommended,
13+
...ts.configs.strict,
14+
...svelte.configs.recommended,
15+
{
16+
rules: {
17+
// typescript-eslint strongly recommend that you do not use the no-undef lint rule on TypeScript projects.
18+
// see: https://typescript-eslint.io/troubleshooting/faqs/eslint/#i-get-errors-from-the-no-undef-rule-about-global-variables-not-being-defined-even-though-there-are-no-typescript-errors
19+
"no-undef": "off",
20+
},
21+
},
22+
{
23+
// Note: there should be no other properties in this object
24+
ignores: ["wasm-lib/*", "dev-dist/*", "coverage/*"],
25+
},
26+
{
27+
files: ["**/*.svelte", "**/*.svelte.ts", "**/*.svelte.js"],
28+
languageOptions: {
29+
parserOptions: {
30+
projectService: true,
31+
extraFileExtensions: [".svelte"],
32+
parser: ts.parser,
33+
svelteConfig,
34+
},
35+
},
36+
}
4437
);

frontend/package.json

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
"type": "module",
66
"scripts": {
77
"test": "vitest",
8-
"wasm": "./scripts/setup.sh",
98
"dev": "vite dev",
109
"build": "vite build",
1110
"preview": "vite preview",
@@ -32,7 +31,6 @@
3231
"eslint": "^9.18",
3332
"eslint-plugin-svelte": "^3.0",
3433
"fake-indexeddb": "^6.0.1",
35-
"globals": "^16.0",
3634
"lucide-svelte": "0.536",
3735
"svelte": "^5.37",
3836
"svelte-check": "4.3",

frontend/scripts/setup.sh

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

frontend/vite.config.ts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,6 @@ export default defineConfig({
4141
server: {
4242
port: 5173,
4343
strictPort: true,
44-
fs: {
45-
allow: ['./wasm-lib/pkg'],
46-
},
4744
host: host || '127.0.0.1',
4845
hmr: host
4946
? {

0 commit comments

Comments
 (0)