Skip to content

Commit

Permalink
fix: publint
Browse files Browse the repository at this point in the history
  • Loading branch information
tannerlinsley committed May 14, 2024
1 parent 3e99326 commit acee5e5
Show file tree
Hide file tree
Showing 7 changed files with 101 additions and 191 deletions.
21 changes: 18 additions & 3 deletions examples/react/basic-ssr-file-based/src/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,22 +49,37 @@ const PostsPostIdRoute = PostsPostIdImport.update({
declare module '@tanstack/react-router' {
interface FileRoutesByPath {
'/': {
id: '/'
path: '/'
fullPath: '/'
preLoaderRoute: typeof IndexImport
parentRoute: typeof rootRoute
}
'/error': {
id: '/error'
path: '/error'
fullPath: '/error'
preLoaderRoute: typeof ErrorImport
parentRoute: typeof rootRoute
}
'/posts': {
id: '/posts'
path: '/posts'
fullPath: '/posts'
preLoaderRoute: typeof PostsImport
parentRoute: typeof rootRoute
}
'/posts/$postId': {
id: '/posts/$postId'
path: '/$postId'
fullPath: '/posts/$postId'
preLoaderRoute: typeof PostsPostIdImport
parentRoute: typeof PostsImport
}
'/posts/': {
id: '/posts/'
path: '/'
fullPath: '/posts/'
preLoaderRoute: typeof PostsIndexImport
parentRoute: typeof PostsImport
}
Expand All @@ -73,10 +88,10 @@ declare module '@tanstack/react-router' {

// Create and export the route tree

export const routeTree = rootRoute.addChildren([
export const routeTree = rootRoute.addChildren({
IndexRoute,
ErrorRoute,
PostsRoute.addChildren([PostsPostIdRoute, PostsIndexRoute]),
])
PostsRoute: PostsRoute.addChildren({ PostsPostIdRoute, PostsIndexRoute }),
})

/* prettier-ignore-end */
21 changes: 18 additions & 3 deletions examples/react/basic-ssr-streaming-file-based/src/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,22 +49,37 @@ const PostsPostIdRoute = PostsPostIdImport.update({
declare module '@tanstack/react-router' {
interface FileRoutesByPath {
'/': {
id: '/'
path: '/'
fullPath: '/'
preLoaderRoute: typeof IndexImport
parentRoute: typeof rootRoute
}
'/error': {
id: '/error'
path: '/error'
fullPath: '/error'
preLoaderRoute: typeof ErrorImport
parentRoute: typeof rootRoute
}
'/posts': {
id: '/posts'
path: '/posts'
fullPath: '/posts'
preLoaderRoute: typeof PostsImport
parentRoute: typeof rootRoute
}
'/posts/$postId': {
id: '/posts/$postId'
path: '/$postId'
fullPath: '/posts/$postId'
preLoaderRoute: typeof PostsPostIdImport
parentRoute: typeof PostsImport
}
'/posts/': {
id: '/posts/'
path: '/'
fullPath: '/posts/'
preLoaderRoute: typeof PostsIndexImport
parentRoute: typeof PostsImport
}
Expand All @@ -73,10 +88,10 @@ declare module '@tanstack/react-router' {

// Create and export the route tree

export const routeTree = rootRoute.addChildren([
export const routeTree = rootRoute.addChildren({
IndexRoute,
ErrorRoute,
PostsRoute.addChildren([PostsPostIdRoute, PostsIndexRoute]),
])
PostsRoute: PostsRoute.addChildren({ PostsPostIdRoute, PostsIndexRoute }),
})

/* prettier-ignore-end */
16 changes: 14 additions & 2 deletions examples/react/vinxi-basic-ssr-streaming/app/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,18 +43,30 @@ const IndexRoute = IndexImport.update({
declare module '@tanstack/react-router' {
interface FileRoutesByPath {
'/': {
id: '/'
path: '/'
fullPath: '/'
preLoaderRoute: typeof IndexImport
parentRoute: typeof rootRoute
}
'/hello': {
id: '/hello'
path: '/hello'
fullPath: '/hello'
preLoaderRoute: typeof HelloImport
parentRoute: typeof rootRoute
}
'/no-title': {
id: '/no-title'
path: '/no-title'
fullPath: '/no-title'
preLoaderRoute: typeof NoTitleImport
parentRoute: typeof rootRoute
}
'/test': {
id: '/test'
path: '/test'
fullPath: '/test'
preLoaderRoute: typeof TestImport
parentRoute: typeof rootRoute
}
Expand All @@ -63,11 +75,11 @@ declare module '@tanstack/react-router' {

// Create and export the route tree

export const routeTree = rootRoute.addChildren([
export const routeTree = rootRoute.addChildren({
IndexRoute,
HelloRoute,
NoTitleRoute,
TestRoute,
])
})

/* prettier-ignore-end */
8 changes: 7 additions & 1 deletion examples/react/vinxi-basic-ssr/app/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,16 @@ const IndexRoute = IndexImport.update({
declare module '@tanstack/react-router' {
interface FileRoutesByPath {
'/': {
id: '/'
path: '/'
fullPath: '/'
preLoaderRoute: typeof IndexImport
parentRoute: typeof rootRoute
}
'/hello': {
id: '/hello'
path: '/hello'
fullPath: '/hello'
preLoaderRoute: typeof HelloImport
parentRoute: typeof rootRoute
}
Expand All @@ -43,6 +49,6 @@ declare module '@tanstack/react-router' {

// Create and export the route tree

export const routeTree = rootRoute.addChildren([IndexRoute, HelloRoute])
export const routeTree = rootRoute.addChildren({ IndexRoute, HelloRoute })

/* prettier-ignore-end */
8 changes: 7 additions & 1 deletion examples/react/vinxi-basic/app/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,16 @@ const IndexRoute = IndexImport.update({
declare module '@tanstack/react-router' {
interface FileRoutesByPath {
'/': {
id: '/'
path: '/'
fullPath: '/'
preLoaderRoute: typeof IndexImport
parentRoute: typeof rootRoute
}
'/hello': {
id: '/hello'
path: '/hello'
fullPath: '/hello'
preLoaderRoute: typeof HelloImport
parentRoute: typeof rootRoute
}
Expand All @@ -43,6 +49,6 @@ declare module '@tanstack/react-router' {

// Create and export the route tree

export const routeTree = rootRoute.addChildren([IndexRoute, HelloRoute])
export const routeTree = rootRoute.addChildren({ IndexRoute, HelloRoute })

/* prettier-ignore-end */
24 changes: 12 additions & 12 deletions packages/start/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@
".": {
"import": {
"types": "./dist/esm/client/index.d.ts",
"default": "./dist/esm/client/index.js"
"default": "./dist/esm/src/client/index.js"
},
"require": {
"types": "./dist/cjs/client/index.d.cts",
"default": "./dist/cjs/client/index.cjs"
"default": "./dist/cjs/src/client/index.cjs"
}
},
"./config": {
Expand All @@ -35,51 +35,51 @@
"./client": {
"import": {
"types": "./dist/esm/client/index.d.ts",
"default": "./dist/esm/client/index.js"
"default": "./dist/esm/src/client/index.js"
},
"require": {
"types": "./dist/cjs/client/index.d.cts",
"default": "./dist/cjs/client/index.cjs"
"default": "./dist/cjs/src/client/index.cjs"
}
},
"./server": {
"import": {
"types": "./dist/esm/server/index.d.ts",
"default": "./dist/esm/server/index.js"
"default": "./dist/esm/src/server/index.js"
},
"require": {
"types": "./dist/cjs/server/index.d.cts",
"default": "./dist/cjs/server/index.cjs"
"default": "./dist/cjs/src/server/index.cjs"
}
},
"./client-runtime": {
"import": {
"types": "./dist/esm/client-runtime/index.d.ts",
"default": "./dist/esm/client-runtime/index.js"
"default": "./dist/esm/src/client-runtime/index.js"
},
"require": {
"types": "./dist/cjs/client-runtime/index.d.cts",
"default": "./dist/cjs/client-runtime/index.cjs"
"default": "./dist/cjs/src/client-runtime/index.cjs"
}
},
"./server-runtime": {
"import": {
"types": "./dist/esm/server-runtime/index.d.ts",
"default": "./dist/esm/server-runtime/index.js"
"default": "./dist/esm/src/server-runtime/index.js"
},
"require": {
"types": "./dist/cjs/server-runtime/index.d.cts",
"default": "./dist/cjs/server-runtime/index.cjs"
"default": "./dist/cjs/src/server-runtime/index.cjs"
}
},
"./server-handler": {
"import": {
"types": "./dist/esm/server-handler/index.d.ts",
"default": "./dist/esm/server-handler/index.js"
"default": "./dist/esm/src/server-handler/index.js"
},
"require": {
"types": "./dist/cjs/server-handler/index.d.cts",
"default": "./dist/cjs/server-handler/index.cjs"
"default": "./dist/cjs/src/server-handler/index.cjs"
}
},
"./package.json": "./package.json"
Expand Down

0 comments on commit acee5e5

Please sign in to comment.