MCPcopy Create free account
hub / github.com/TryCatchLearn/Restore-v2 / createFormData

Function createFormData

client/src/features/admin/ProductForm.tsx:40–47  ·  view source on GitHub ↗
(items: FieldValues)

Source from the content-addressed store, hash-verified

38 }, [product, reset, watchFile]);
39
40 const createFormData = (items: FieldValues) => {
41 const formData = new FormData();
42 for (const key in items) {
43 formData.append(key, items[key])
44 }
45
46 return formData;
47 }
48
49 const onSubmit = async (data: CreateProductSchema) => {
50 try {

Callers 1

onSubmitFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected