From c7f2f4aeae2980eb32b66951ed2e1bce3f72cff2 Mon Sep 17 00:00:00 2001
From: wont-stream <143244075+wont-stream@users.noreply.github.com>
Date: Thu, 10 Apr 2025 19:16:51 -0400
Subject: [PATCH] Linting
---
biome.json | 1 -
src/components/container/index.tsx | 2 +-
src/components/sidebar/index.tsx | 42 +++++++++++++++---------------
src/main.tsx | 2 +-
tsconfig.app.json | 5 +---
tsconfig.node.json | 2 --
6 files changed, 24 insertions(+), 30 deletions(-)
diff --git a/biome.json b/biome.json
index 921a7a5..029c240 100644
--- a/biome.json
+++ b/biome.json
@@ -27,7 +27,6 @@
"formatter": {
"quoteStyle": "double",
"indentStyle": "tab",
- "lineEnding": "lf",
"jsxQuoteStyle": "double",
"semicolons": "always"
}
diff --git a/src/components/container/index.tsx b/src/components/container/index.tsx
index f6455df..c803359 100644
--- a/src/components/container/index.tsx
+++ b/src/components/container/index.tsx
@@ -6,7 +6,7 @@ export default () => {
halfPage is a minimalistic startpage, built on only open-source software.
halfmoon wttr.in diff --git a/src/main.tsx b/src/main.tsx index b1cc976..b30ffd1 100644 --- a/src/main.tsx +++ b/src/main.tsx @@ -5,7 +5,7 @@ import 'halfmoon/css/cores/halfmoon.modern.css'; import 'halfmoon/css/cores/halfmoon.elegant.css'; import App from './components/app.tsx' -const dataset = document.getElementById("html")!.dataset; +const dataset = document.getElementById("html")?.dataset!; const colorScheme = localStorage.getItem("colorScheme") || (window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light") || "auto"; if (colorScheme === "auto") { diff --git a/tsconfig.app.json b/tsconfig.app.json index d5cbc23..b0fe4f6 100644 --- a/tsconfig.app.json +++ b/tsconfig.app.json @@ -10,8 +10,6 @@ "react": ["./node_modules/preact/compat/"], "react-dom": ["./node_modules/preact/compat/"] }, - - /* Bundler mode */ "moduleResolution": "bundler", "allowImportingTsExtensions": true, "isolatedModules": true, @@ -19,8 +17,7 @@ "noEmit": true, "jsx": "react-jsx", "jsxImportSource": "preact", - - /* Linting */ + "strict": true, "noUnusedLocals": true, "noUnusedParameters": true, diff --git a/tsconfig.node.json b/tsconfig.node.json index db0becc..c921d97 100644 --- a/tsconfig.node.json +++ b/tsconfig.node.json @@ -6,14 +6,12 @@ "module": "ESNext", "skipLibCheck": true, - /* Bundler mode */ "moduleResolution": "bundler", "allowImportingTsExtensions": true, "isolatedModules": true, "moduleDetection": "force", "noEmit": true, - /* Linting */ "strict": true, "noUnusedLocals": true, "noUnusedParameters": true,