Skip to content

Commit b6bca9c

Browse files
committed
fix: bug with query editor not rendering
1 parent 7223b62 commit b6bca9c

File tree

2 files changed

+5
-14
lines changed

2 files changed

+5
-14
lines changed

ui/biome.json

Lines changed: 3 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,7 @@
77
},
88
"files": {
99
"ignoreUnknown": false,
10-
"includes": [
11-
"**",
12-
"!dist/**",
13-
"!.tanstack/**",
14-
"!src/routeTree.gen.ts"
15-
]
10+
"includes": ["**", "!dist/**", "!.tanstack/**", "!src/routeTree.gen.ts"]
1611
},
1712
"formatter": {
1813
"enabled": true,
@@ -102,12 +97,7 @@
10297
},
10398
"overrides": [
10499
{
105-
"includes": [
106-
"*.ts",
107-
"*.tsx",
108-
"*.mts",
109-
"*.cts"
110-
],
100+
"includes": ["*.ts", "*.tsx", "*.mts", "*.cts"],
111101
"linter": {
112102
"rules": {
113103
"complexity": {
@@ -149,4 +139,4 @@
149139
}
150140
}
151141
}
152-
}
142+
}

ui/src/components/editor.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ export const Editor: FunctionComponent<Props> = ({ value, onChange }) => {
2929
queryFn: () => fetchAutocomplete(),
3030
});
3131

32+
// biome-ignore lint: lint/correctness/useExhaustiveDependencies: the fix doesn't work
3233
useEffect(() => {
3334
if (monacoEl) {
3435
setEditor((editor) => {
@@ -68,7 +69,7 @@ export const Editor: FunctionComponent<Props> = ({ value, onChange }) => {
6869
}
6970

7071
return () => editor?.dispose();
71-
}, [editor?.dispose, onChange, value]);
72+
}, [monacoEl.current]);
7273

7374
useEffect(() => {
7475
if (!autoCompleteData) return;

0 commit comments

Comments
 (0)