Lint stuff

This commit is contained in:
Gregory Schier
2026-03-08 15:50:13 -07:00
parent 96a22c68f2
commit 6e11894f79
4 changed files with 35 additions and 20 deletions

View File

@@ -5,8 +5,6 @@
"useDefineForClassFields": true,
"allowJs": false,
"skipLibCheck": true,
"esModuleInterop": false,
"allowSyntheticDefaultImports": true,
"strict": true,
"noUncheckedIndexedAccess": true,
"forceConsistentCasingInFileNames": true,
@@ -16,7 +14,6 @@
"isolatedModules": true,
"noEmit": true,
"jsx": "react-jsx",
"baseUrl": ".",
"paths": {
"@yaakapp-internal/theme": ["../../packages/theme/src/index.ts"],
"@yaakapp-internal/theme/*": ["../../packages/theme/src/*"],

View File

@@ -22,7 +22,9 @@ export function listen<K extends keyof RpcEventSchema>(
): () => void {
let unsub: (() => void) | null = null;
tauriListen<RpcEventSchema[K]>(event, (e) => callback(e.payload))
.then((fn) => (unsub = fn))
.then((fn) => {
unsub = fn;
})
.catch(console.error);
return () => unsub?.();
}

View File

@@ -1,8 +1,12 @@
import { createModelStore } from "@yaakapp-internal/model-store";
import type { HttpExchange } from "../../crates-proxy/yaak-proxy-lib/bindings/gen_models";
type ProxyModels = {
http_exchange: HttpExchange;
};
export const { dataAtom, applyChange, listAtom, orderedListAtom } =
createModelStore<HttpExchange>();
createModelStore<ProxyModels>(["http_exchange"]);
export const httpExchangesAtom = orderedListAtom(
"http_exchange",