@tanstack/react-form-remix 1.27.7 → 1.28.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { AnyFormApi
|
|
2
|
-
export declare
|
|
1
|
+
import { AnyFormApi } from '@tanstack/react-form';
|
|
2
|
+
export declare const useTransform: (fn: (formBase: AnyFormApi) => AnyFormApi, deps?: unknown[]) => (data: unknown) => unknown;
|
package/dist/esm/useTransform.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useTransform.js","sources":["../../src/useTransform.ts"],"sourcesContent":["import type { AnyFormApi
|
|
1
|
+
{"version":3,"file":"useTransform.js","sources":["../../src/useTransform.ts"],"sourcesContent":["import { useCallback } from 'react'\nimport type { AnyFormApi } from '@tanstack/react-form'\n\nexport const useTransform: (\n fn: (formBase: AnyFormApi) => AnyFormApi,\n deps?: unknown[],\n) => (data: unknown) => unknown = useCallback as never\n"],"names":[],"mappings":";AAGO,MAAM,eAGqB;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tanstack/react-form-remix",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.28.1",
|
|
4
4
|
"description": "Powerful, type-safe forms for React.",
|
|
5
5
|
"author": "tannerlinsley",
|
|
6
6
|
"license": "MIT",
|
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
],
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"decode-formdata": "^0.9.0",
|
|
36
|
-
"@tanstack/react-form": "1.
|
|
36
|
+
"@tanstack/react-form": "1.28.1"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
39
|
"@tanstack/react-start": "^1.134.9",
|
package/src/useTransform.ts
CHANGED
|
@@ -1,11 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { useCallback } from 'react'
|
|
2
|
+
import type { AnyFormApi } from '@tanstack/react-form'
|
|
2
3
|
|
|
3
|
-
export
|
|
4
|
+
export const useTransform: (
|
|
4
5
|
fn: (formBase: AnyFormApi) => AnyFormApi,
|
|
5
|
-
deps
|
|
6
|
-
)
|
|
7
|
-
return {
|
|
8
|
-
fn,
|
|
9
|
-
deps,
|
|
10
|
-
}
|
|
11
|
-
}
|
|
6
|
+
deps?: unknown[],
|
|
7
|
+
) => (data: unknown) => unknown = useCallback as never
|