Skip to content
Open
Show file tree
Hide file tree
Changes from 8 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/cruel-clubs-agree.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@tanstack/react-form': major
---

Update Start to Release Candidate version
15 changes: 15 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ env:

permissions:
contents: read
pull-requests: write

jobs:
test:
Expand Down Expand Up @@ -59,3 +60,17 @@ jobs:
run: pnpm run build:all
- name: Publish Previews
run: pnpx pkg-pr-new publish --pnpm --compact './packages/*' --template './examples/*/*'
check-deps:
name: Check Dependencies
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
with:
fetch-depth: 0
- name: Check Dependencies
uses: e18e/action-dependency-diff@main
- name: Check Provenance
uses: danielroe/[email protected]
with:
fail-on-downgrade: true
4 changes: 2 additions & 2 deletions examples/react/tanstack-start/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
"@tanstack/react-devtools": "^0.7.0",
"@tanstack/react-form": "^1.23.4",
"@tanstack/react-form-devtools": "^0.1.4",
"@tanstack/react-router": "^1.131.50",
"@tanstack/react-start": "^1.131.50",
"@tanstack/react-router": "^1.132.6",
"@tanstack/react-start": "^1.132.6",
"@tanstack/react-store": "^0.7.7",
"react": "^19.0.0",
"react-dom": "^19.0.0"
Expand Down
8 changes: 8 additions & 0 deletions examples/react/tanstack-start/src/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,11 @@ const rootRouteChildren: RootRouteChildren = {
export const routeTree = rootRouteImport
._addFileChildren(rootRouteChildren)
._addFileTypes<FileRouteTypes>()

import type { getRouter } from './router.tsx'
import type { createStart } from '@tanstack/react-start'
declare module '@tanstack/react-start' {
interface Register {
router: Awaited<ReturnType<typeof getRouter>>
}
}
4 changes: 2 additions & 2 deletions examples/react/tanstack-start/src/router.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { createRouter as createTanStackRouter } from '@tanstack/react-router'
import { routeTree } from './routeTree.gen'

export function createRouter() {
export function getRouter() {
const router = createTanStackRouter({
routeTree,
defaultPreload: 'intent',
Expand All @@ -13,6 +13,6 @@ export function createRouter() {

declare module '@tanstack/react-router' {
interface Register {
router: ReturnType<typeof createRouter>
router: ReturnType<typeof getRouter>
}
}
7 changes: 2 additions & 5 deletions examples/react/tanstack-start/src/utils/form.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,8 @@ const serverValidate = createServerValidate({
},
})

export const handleForm = createServerFn({
method: 'POST',
response: 'raw',
})
.validator((data: unknown) => {
export const handleForm = createServerFn({ method: 'POST' })
.inputValidator((data: unknown) => {
if (!(data instanceof FormData)) {
throw new Error('Invalid form data')
}
Expand Down
4 changes: 2 additions & 2 deletions packages/react-form/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@
"devalue": "^5.3.2"
},
"devDependencies": {
"@tanstack/react-start": "^1.131.50",
"@tanstack/react-start": "^1.132.6",
"@types/react": "^19.0.7",
"@types/react-dom": "^19.0.3",
"@vitejs/plugin-react": "^4.7.0",
Expand All @@ -97,7 +97,7 @@
"vite": "^7.1.6"
},
"peerDependencies": {
"@tanstack/react-start": "^1.130.10",
"@tanstack/react-start": "^1.132.6",
"react": "^17.0.0 || ^18.0.0 || ^19.0.0"
},
"peerDependenciesMeta": {
Expand Down
4 changes: 2 additions & 2 deletions packages/react-form/src/start/createServerValidate.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import {
isStandardSchemaValidator,
standardSchemaValidators,
} from '@tanstack/form-core'
import { getHeader } from '@tanstack/react-start/server'
import { getRequestHeader } from '@tanstack/react-start/server'
import { decode } from 'decode-formdata'
import { ServerValidateError } from './error'
import { setInternalTanStackCookie } from './utils'
Expand Down Expand Up @@ -99,7 +99,7 @@ export const createServerValidate =
})
}

const referer = getHeader('referer')!
const referer = getRequestHeader('referer')!

const data = decode(formData, info) as never as TFormData

Expand Down
8,688 changes: 3,433 additions & 5,255 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

Loading