Skip to content

Commit 6d592db

Browse files
committed
fix(typesync | publish): bump deps. fix tanstack router plugin codegen.
1 parent 4b14c79 commit 6d592db

File tree

7 files changed

+1249
-1371
lines changed

7 files changed

+1249
-1371
lines changed

apps/typesync/client/src/routeTree.gen.ts

Lines changed: 38 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -8,82 +8,43 @@
88
// You should NOT make any changes in this file as it will be overwritten.
99
// Additionally, you should also exclude this file from your linter and/or formatter to prevent it from being checked or modified.
1010

11-
// Import Routes
11+
import { Route as rootRouteImport } from './routes/__root'
12+
import { Route as IndexRouteImport } from './routes/index'
13+
import { Route as AppsCreateRouteImport } from './routes/apps/create'
14+
import { Route as AppsAppIdDetailsRouteImport } from './routes/apps/$appId/details'
1215

13-
import { Route as rootRoute } from './routes/__root'
14-
import { Route as IndexImport } from './routes/index'
15-
import { Route as AppsCreateImport } from './routes/apps/create'
16-
import { Route as AppsAppIdDetailsImport } from './routes/apps/$appId/details'
17-
18-
// Create/Update Routes
19-
20-
const IndexRoute = IndexImport.update({
16+
const IndexRoute = IndexRouteImport.update({
2117
id: '/',
2218
path: '/',
23-
getParentRoute: () => rootRoute,
19+
getParentRoute: () => rootRouteImport,
2420
} as any)
25-
26-
const AppsCreateRoute = AppsCreateImport.update({
21+
const AppsCreateRoute = AppsCreateRouteImport.update({
2722
id: '/apps/create',
2823
path: '/apps/create',
29-
getParentRoute: () => rootRoute,
24+
getParentRoute: () => rootRouteImport,
3025
} as any)
31-
32-
const AppsAppIdDetailsRoute = AppsAppIdDetailsImport.update({
26+
const AppsAppIdDetailsRoute = AppsAppIdDetailsRouteImport.update({
3327
id: '/apps/$appId/details',
3428
path: '/apps/$appId/details',
35-
getParentRoute: () => rootRoute,
29+
getParentRoute: () => rootRouteImport,
3630
} as any)
3731

38-
// Populate the FileRoutesByPath interface
39-
40-
declare module '@tanstack/react-router' {
41-
interface FileRoutesByPath {
42-
'/': {
43-
id: '/'
44-
path: '/'
45-
fullPath: '/'
46-
preLoaderRoute: typeof IndexImport
47-
parentRoute: typeof rootRoute
48-
}
49-
'/apps/create': {
50-
id: '/apps/create'
51-
path: '/apps/create'
52-
fullPath: '/apps/create'
53-
preLoaderRoute: typeof AppsCreateImport
54-
parentRoute: typeof rootRoute
55-
}
56-
'/apps/$appId/details': {
57-
id: '/apps/$appId/details'
58-
path: '/apps/$appId/details'
59-
fullPath: '/apps/$appId/details'
60-
preLoaderRoute: typeof AppsAppIdDetailsImport
61-
parentRoute: typeof rootRoute
62-
}
63-
}
64-
}
65-
66-
// Create and export the route tree
67-
6832
export interface FileRoutesByFullPath {
6933
'/': typeof IndexRoute
7034
'/apps/create': typeof AppsCreateRoute
7135
'/apps/$appId/details': typeof AppsAppIdDetailsRoute
7236
}
73-
7437
export interface FileRoutesByTo {
7538
'/': typeof IndexRoute
7639
'/apps/create': typeof AppsCreateRoute
7740
'/apps/$appId/details': typeof AppsAppIdDetailsRoute
7841
}
79-
8042
export interface FileRoutesById {
81-
__root__: typeof rootRoute
43+
__root__: typeof rootRouteImport
8244
'/': typeof IndexRoute
8345
'/apps/create': typeof AppsCreateRoute
8446
'/apps/$appId/details': typeof AppsAppIdDetailsRoute
8547
}
86-
8748
export interface FileRouteTypes {
8849
fileRoutesByFullPath: FileRoutesByFullPath
8950
fullPaths: '/' | '/apps/create' | '/apps/$appId/details'
@@ -92,43 +53,43 @@ export interface FileRouteTypes {
9253
id: '__root__' | '/' | '/apps/create' | '/apps/$appId/details'
9354
fileRoutesById: FileRoutesById
9455
}
95-
9656
export interface RootRouteChildren {
9757
IndexRoute: typeof IndexRoute
9858
AppsCreateRoute: typeof AppsCreateRoute
9959
AppsAppIdDetailsRoute: typeof AppsAppIdDetailsRoute
10060
}
10161

62+
declare module '@tanstack/react-router' {
63+
interface FileRoutesByPath {
64+
'/': {
65+
id: '/'
66+
path: '/'
67+
fullPath: '/'
68+
preLoaderRoute: typeof IndexRouteImport
69+
parentRoute: typeof rootRouteImport
70+
}
71+
'/apps/create': {
72+
id: '/apps/create'
73+
path: '/apps/create'
74+
fullPath: '/apps/create'
75+
preLoaderRoute: typeof AppsCreateRouteImport
76+
parentRoute: typeof rootRouteImport
77+
}
78+
'/apps/$appId/details': {
79+
id: '/apps/$appId/details'
80+
path: '/apps/$appId/details'
81+
fullPath: '/apps/$appId/details'
82+
preLoaderRoute: typeof AppsAppIdDetailsRouteImport
83+
parentRoute: typeof rootRouteImport
84+
}
85+
}
86+
}
87+
10288
const rootRouteChildren: RootRouteChildren = {
10389
IndexRoute: IndexRoute,
10490
AppsCreateRoute: AppsCreateRoute,
10591
AppsAppIdDetailsRoute: AppsAppIdDetailsRoute,
10692
}
107-
108-
export const routeTree = rootRoute
93+
export const routeTree = rootRouteImport
10994
._addFileChildren(rootRouteChildren)
11095
._addFileTypes<FileRouteTypes>()
111-
112-
/* ROUTE_MANIFEST_START
113-
{
114-
"routes": {
115-
"__root__": {
116-
"filePath": "__root.tsx",
117-
"children": [
118-
"/",
119-
"/apps/create",
120-
"/apps/$appId/details"
121-
]
122-
},
123-
"/": {
124-
"filePath": "index.tsx"
125-
},
126-
"/apps/create": {
127-
"filePath": "apps/create.tsx"
128-
},
129-
"/apps/$appId/details": {
130-
"filePath": "apps/$appId/details.tsx"
131-
}
132-
}
133-
}
134-
ROUTE_MANIFEST_END */

apps/typesync/package.json

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
2-
"name": "@graphprotocol/typesync-cli",
3-
"version": "0.0.0-alpha.6",
2+
"name": "@graphprotocol/hypergraph-cli",
3+
"version": "0.0.0-alpha.7",
44
"type": "module",
55
"license": "MIT",
66
"description": "CLI toolchain to view existing types, select, pick, extend to create schemas and generate a @graphprotocol/hypergraph schema.",
@@ -24,7 +24,7 @@
2424
"build:client": "vite build",
2525
"build": "rm -rf ./client/dist && pnpm run build:client && tsup && pnpm run copy-all",
2626
"build:ts": "tsup",
27-
"dev": "vite build && pnpx tsx ./src/bin.ts",
27+
"dev": "vite build && pnpx tsx ./src/bin.ts typesync",
2828
"dev:cli": "pnpx tsx ./src/bin.ts typesync",
2929
"dev:client": "vite --force",
3030
"clean": "rimraf dist/*",
@@ -47,16 +47,16 @@
4747
"@effect/sql": "latest",
4848
"@effect/sql-sqlite-node": "latest",
4949
"@effect/vitest": "latest",
50-
"@graphprotocol/grc-20": "^0.18.0",
50+
"@graphprotocol/grc-20": "^0.21.3",
5151
"@graphql-codegen/cli": "^5.0.7",
52-
"@graphql-codegen/client-preset": "^4.8.2",
52+
"@graphql-codegen/client-preset": "^4.8.3",
5353
"@graphql-codegen/typescript": "^4.1.6",
5454
"@graphql-codegen/typescript-operations": "^4.6.1",
55-
"@tanstack/router-plugin": "^1.121.10",
56-
"@types/node": "^24.0.1",
55+
"@tanstack/router-plugin": "^1.121.41",
56+
"@types/node": "^24.0.5",
5757
"@types/react": "^19.1.8",
5858
"@types/react-dom": "^19.1.6",
59-
"@vitejs/plugin-react": "^4.5.2",
59+
"@vitejs/plugin-react": "^4.6.0",
6060
"glob": "^11.0.3",
6161
"tsup": "^8.5.0",
6262
"tsx": "^4.20.3",
@@ -68,13 +68,13 @@
6868
"@heroicons/react": "^2.2.0",
6969
"@phosphor-icons/react": "^2.1.10",
7070
"@radix-ui/react-tabs": "^1.1.12",
71-
"@tailwindcss/vite": "^4.1.10",
72-
"@tanstack/react-form": "^1.12.3",
73-
"@tanstack/react-query": "^5.80.7",
74-
"@tanstack/react-query-devtools": "^5.80.7",
75-
"@tanstack/react-router": "^1.121.2",
76-
"@tanstack/react-router-devtools": "1.121.8",
77-
"better-sqlite3": "^11.10.0",
71+
"@tailwindcss/vite": "^4.1.11",
72+
"@tanstack/react-form": "^1.12.4",
73+
"@tanstack/react-query": "^5.81.4",
74+
"@tanstack/react-query-devtools": "^5.81.4",
75+
"@tanstack/react-router": "^1.121.41",
76+
"@tanstack/react-router-devtools": "1.121.41",
77+
"better-sqlite3": "^12.1.1",
7878
"date-fns": "^4.1.0",
7979
"effect": "^3.16.10",
8080
"graphql": "^16.11.0",
@@ -83,7 +83,7 @@
8383
"open": "^10.1.2",
8484
"react": "^19.1.0",
8585
"react-dom": "^19.1.0",
86-
"shiki": "^3.6.0",
87-
"tailwindcss": "^4.1.10"
86+
"shiki": "^3.7.0",
87+
"tailwindcss": "^4.1.11"
8888
}
8989
}

apps/typesync/src/Generator.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,7 @@ import * as nodePath from 'node:path';
44
import * as NodeFileSystem from '@effect/platform-node/NodeFileSystem';
55
import * as FileSystem from '@effect/platform/FileSystem';
66
import * as Path from '@effect/platform/Path';
7-
import * as Data from 'effect/Data';
8-
import * as Effect from 'effect/Effect';
7+
import { Data, Effect } from 'effect';
98

109
import * as Domain from '../domain/Domain.js';
1110
import * as Utils from './Utils.js';

apps/typesync/src/migrations/_schema.sql

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,8 @@ CREATE TABLE app_schema_type_property (
5050
CONSTRAINT unq__app_schema_type_property__app_schema_type_id_name UNIQUE (app_schema_type_id, name)
5151
);
5252

53-
INSERT INTO effect_sql_migrations VALUES(1,'2025-04-13 19:53:24','create_table__app');
54-
INSERT INTO effect_sql_migrations VALUES(2,'2025-04-13 19:53:24','create_table__app_events');
55-
INSERT INTO effect_sql_migrations VALUES(3,'2025-04-13 19:53:24','create_table__app_schema');
56-
INSERT INTO effect_sql_migrations VALUES(4,'2025-04-13 19:53:24','create_table__app_schema_type_property');
57-
INSERT INTO effect_sql_migrations VALUES(5,'2025-06-12 22:30:11','update_table_property_relationTypeName');
53+
INSERT INTO effect_sql_migrations VALUES(1,'2025-06-27 18:52:18','create_table__app');
54+
INSERT INTO effect_sql_migrations VALUES(2,'2025-06-27 18:52:18','create_table__app_events');
55+
INSERT INTO effect_sql_migrations VALUES(3,'2025-06-27 18:52:18','create_table__app_schema');
56+
INSERT INTO effect_sql_migrations VALUES(4,'2025-06-27 18:52:18','create_table__app_schema_type_property');
57+
INSERT INTO effect_sql_migrations VALUES(5,'2025-06-27 18:52:18','update_table_property_relationTypeName');

apps/typesync/vite.config.ts

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import tailwindcss from '@tailwindcss/vite';
2-
import { TanStackRouterVite } from '@tanstack/router-plugin/vite';
2+
import { tanstackRouter } from '@tanstack/router-plugin/vite';
33
import react from '@vitejs/plugin-react';
44
import { defineConfig } from 'vite';
55

@@ -8,13 +8,23 @@ import 'react-dom';
88

99
export default defineConfig({
1010
root: './client',
11-
// server: {
12-
// port: 3000,
13-
// },
14-
// preview: {
15-
// port: 5000,
16-
// },
17-
plugins: [TanStackRouterVite({ autoCodeSplitting: true }), react(), tailwindcss()],
11+
server: {
12+
port: 3000,
13+
},
14+
preview: {
15+
port: 5000,
16+
},
17+
plugins: [
18+
tanstackRouter({
19+
target: 'react',
20+
quoteStyle: 'single',
21+
autoCodeSplitting: true,
22+
routesDirectory: 'client/src/routes',
23+
generatedRouteTree: 'client/src/routeTree.gen.ts',
24+
}),
25+
react(),
26+
tailwindcss(),
27+
],
1828
optimizeDeps: {
1929
include: ['react/jsx-runtime'],
2030
},

0 commit comments

Comments
 (0)