Skip to content

Commit 6bfc648

Browse files
committed
suspense
1 parent 9eee928 commit 6bfc648

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

apps/web/src/app/page.tsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,15 @@ import { checkToolState, InvalidTokenError } from '@/lib/tinybird';
88
import { TOOLS, type AppGridItem, type ToolState } from '@/lib/constants';
99
import TokenPrompt from '@/components/token-prompt';
1010
import { SectionHeader } from '@/components/section-header';
11+
import { Suspense } from 'react';
1112

12-
export default function Home() {
13+
export default function Page() {
14+
<Suspense>
15+
<Home />
16+
</Suspense>
17+
}
18+
19+
function Home() {
1320
const [token, setToken] = useQueryState('token');
1421
const [toolStates, setToolStates] = useState<Record<string, ToolState>>({});
1522
const [isLoading, setIsLoading] = useState(false);

apps/web/src/lib/tinybird.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
/* eslint-disable @typescript-eslint/no-explicit-any */
2+
13
import { type ToolState } from './constants';
24

35
export class InvalidTokenError extends Error {
@@ -35,7 +37,7 @@ export async function listDataSources(token: string): Promise<TinybirdDataSource
3537

3638
export interface QueryResult {
3739
meta: Array<{ name: string; type: string }>;
38-
data: Array<Record<string, unknown>>;
40+
data: Array<Record<string, any>>;
3941
rows: number;
4042
statistics: {
4143
elapsed: number;

0 commit comments

Comments
 (0)