formatting changes

This commit is contained in:
Lucas Jensen
2024-06-26 19:44:33 -07:00
parent 6395537c29
commit 18f7366ae6
7 changed files with 21 additions and 27 deletions

View File

@@ -2,17 +2,17 @@ module.exports = {
root: true, root: true,
env: { browser: true, es2020: true }, env: { browser: true, es2020: true },
extends: [ extends: [
'eslint:recommended', "eslint:recommended",
'plugin:@typescript-eslint/recommended', "plugin:@typescript-eslint/recommended",
'plugin:react-hooks/recommended', "plugin:react-hooks/recommended",
], ],
ignorePatterns: ['dist', '.eslintrc.cjs'], ignorePatterns: ["dist", ".eslintrc.cjs"],
parser: '@typescript-eslint/parser', parser: "@typescript-eslint/parser",
plugins: ['react-refresh'], plugins: ["react-refresh"],
rules: { rules: {
'react-refresh/only-export-components': [ "react-refresh/only-export-components": [
'warn', "warn",
{ allowConstantExport: true }, { allowConstantExport: true },
], ],
}, },
} };

View File

@@ -1,4 +1,4 @@
<!DOCTYPE html> <!doctype html>
<html lang="en"> <html lang="en">
<head> <head>
<meta charset="UTF-8" /> <meta charset="UTF-8" />

View File

@@ -7,7 +7,9 @@
"dev": "vite --port 3000", "dev": "vite --port 3000",
"build": "tsc && vite build", "build": "tsc && vite build",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0", "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"preview": "vite preview" "preview": "vite preview",
"prettier:check": "npx prettier --check .",
"prettier:fix": "npx prettier --write ."
}, },
"dependencies": { "dependencies": {
"@auth0/auth0-react": "^2.2.4", "@auth0/auth0-react": "^2.2.4",
@@ -40,4 +42,4 @@
"vite": "^5.0.8", "vite": "^5.0.8",
"vitest": "^1.2.0" "vitest": "^1.2.0"
} }
} }

View File

@@ -6,7 +6,7 @@ export const API_URL = API_URL_ENV.endsWith("/")
export async function fetchFromApi( export async function fetchFromApi(
endpoint: string, endpoint: string,
method: string = "GET", method: string = "GET",
body?: unknown body?: unknown,
) { ) {
try { try {
const options: RequestInit = { const options: RequestInit = {

View File

@@ -18,5 +18,5 @@ ReactDOM.createRoot(document.getElementById("root")!).render(
> >
<App /> <App />
</Auth0Provider> </Auth0Provider>
</React.StrictMode> </React.StrictMode>,
); );

View File

@@ -2,11 +2,7 @@
"compilerOptions": { "compilerOptions": {
"target": "ES2020", "target": "ES2020",
"useDefineForClassFields": true, "useDefineForClassFields": true,
"lib": [ "lib": ["ES2020", "DOM", "DOM.Iterable"],
"ES2020",
"DOM",
"DOM.Iterable"
],
"module": "ESNext", "module": "ESNext",
"skipLibCheck": true, "skipLibCheck": true,
/* Bundler mode */ /* Bundler mode */
@@ -22,12 +18,10 @@
"noUnusedParameters": true, "noUnusedParameters": true,
"noFallthroughCasesInSwitch": true "noFallthroughCasesInSwitch": true
}, },
"include": [ "include": ["src"],
"src"
],
"references": [ "references": [
{ {
"path": "./tsconfig.node.json" "path": "./tsconfig.node.json"
} }
] ]
} }

View File

@@ -6,7 +6,5 @@
"moduleResolution": "bundler", "moduleResolution": "bundler",
"allowSyntheticDefaultImports": true "allowSyntheticDefaultImports": true
}, },
"include": [ "include": ["vite.config.ts"]
"vite.config.ts" }
]
}