Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 17 additions & 0 deletions frontend/.oxfmtrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"ignorePatterns": [
"**/*.yml",
"**/*.yaml",
"**/*.json",
"**/*.jsonc",
"**/*.css",
"**/*.md",
"**/npm-cache/**",
"**/vendor/**",
"**/dist/**",
"**/build/**",
"**/coverage/**",
"**/.venv/**",
"**/__snapshots__/**"
]
}
38 changes: 38 additions & 0 deletions frontend/.oxlintrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"$schema": "https://raw.githubusercontent.com/oxc-project/oxc/main/npm/oxlint/configuration_schema.json",
"plugins": [
"typescript",
"unicorn",
"oxc",
"import",
"promise",
"node",
"jsdoc",
"vitest",
"react",
"react-perf",
"jsx-a11y",
"vue"
],
"categories": {
"correctness": "error"
},
"rules": {
"vitest/require-to-throw-message": "off"
},
"env": {
"builtin": true,
"browser": true,
"node": true
},
"ignorePatterns": [
"**/node_modules/**",
"**/npm-cache/**",
"**/vendor/**",
"**/dist/**",
"**/build/**",
"**/coverage/**",
"**/.venv/**",
"**/__snapshots__/**"
]
}
5 changes: 4 additions & 1 deletion frontend/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,10 @@ build:
npm run build

lint:
npx biome check .
npm run lint

lint-fix:
npm run lint:fix

test:
echo no tests
30 changes: 0 additions & 30 deletions frontend/biome.json

This file was deleted.

8 changes: 5 additions & 3 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@
"scripts": {
"dev": "vite --host",
"build": "tsc && npx vite build",
"lint": "biome check .",
"preview": "vite preview"
"lint": "oxlint",
"preview": "vite preview",
"lint:fix": "oxfmt && oxlint --fix"
},
"dependencies": {
"axios": "^1.11.0",
Expand All @@ -20,11 +21,12 @@
"url": "^0.11.4"
},
"devDependencies": {
"@biomejs/biome": "^1.9.0",
"@types/react": "^19.1.12",
"@types/react-dom": "^19.1.9",
"@vitejs/plugin-react": "^5.0.2",
"npm-check-updates": "^18.1.0",
"oxfmt": "^0.63.0",
"oxlint": "^1.78.0",
"typescript": "^5.9.2",
"vite": "^7.1.5"
}
Expand Down
16 changes: 2 additions & 14 deletions frontend/src/App.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
import jsonServerProvider from "ra-data-json-server";
import {
Admin,
ListGuesser,
Resource,
ShowGuesser,
fetchUtils,
} from "react-admin";
import { Admin, ListGuesser, Resource, ShowGuesser, fetchUtils } from "react-admin";

import authProvider from "./authProvider";
import { Dashboard } from "./components/Dashboard";
Expand All @@ -30,13 +24,7 @@ const App = () => (
dataProvider={dataProvider}
// requireAuth
>
<Resource
name="posts"
create={PostCreate}
list={PostList}
show={PostShow}
edit={PostEdit}
/>
<Resource name="posts" create={PostCreate} list={PostList} show={PostShow} edit={PostEdit} />

<Resource
name="users"
Expand Down
7 changes: 1 addition & 6 deletions frontend/src/components/users.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,4 @@
import {
Datagrid,
DateField,
List,
TextField,
} from "react-admin";
import { Datagrid, DateField, List, TextField } from "react-admin";

export const UserList = () => (
<List>
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,5 @@ import App from "./App";
ReactDOM.createRoot(document.getElementById("root")!).render(
<React.StrictMode>
<App />
</React.StrictMode>
</React.StrictMode>,
);
8 changes: 4 additions & 4 deletions frontend/src/runServer.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { createServer } from 'vite';
import { createServer } from "vite";
import react from "@vitejs/plugin-react";
import path from 'node:path';
import path from "node:path";

import { fileURLToPath } from 'url';
import { fileURLToPath } from "url";

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
Expand All @@ -11,7 +11,7 @@ const app = async () => {
const vite = await createServer({
plugins: [react()],
configFile: false,
root: path.resolve(__dirname, '../dist'),
root: path.resolve(__dirname, "../dist"),
});
await vite.listen();
};
Expand Down
4 changes: 2 additions & 2 deletions frontend/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ export default defineConfig({
server: {
host: true,
proxy: {
'/api': {
target: 'http://localhost:8080',
"/api": {
target: "http://localhost:8080",
},
},
},
Expand Down