Skip to content

Commit 44253ca

Browse files
committed
Use formik 'FastField' instead of 'Field' for performance reasons
On an Opencast system with a large number of series (>4,000), entering text in the create or edit event dialogue box is slow. Using the formik 'FastField' instead of 'Field' improves the performance. Fixes #1406
1 parent e5714a7 commit 44253ca

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

src/components/shared/Field.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
import { Field as FormikField } from "formik";
1+
import { FastField as FormikFastField } from "formik";
22
import { FieldAttributes } from "formik/dist/Field";
33

44
/**
55
* Wrapper for the Formik Fields
66
*/
77
export const Field = (props: FieldAttributes<any>) => {
88
return (
9-
<FormikField
9+
<FormikFastField
1010
{...props}
1111
onKeyDown={(event: KeyboardEvent) => {
1212
// Handler for basic html inputs to remove focus, if no custom component is passed

0 commit comments

Comments
 (0)