chore: change order of hooks

Signed-off-by: blam <ben@blam.sh>
This commit is contained in:
blam
2023-01-25 15:29:21 +01:00
parent 66948f1a99
commit 2b27e58084
@@ -127,6 +127,8 @@ export const Stepper = (stepperProps: StepperProps) => {
[setFormState],
);
const currentStep = useTransformSchemaToProps(steps[activeStep], { layouts });
const handleNext = async ({
formData = {},
}: {
@@ -151,8 +153,6 @@ export const Stepper = (stepperProps: StepperProps) => {
setFormState(current => ({ ...current, ...formData }));
};
const currentStep = useTransformSchemaToProps(steps[activeStep], { layouts });
return (
<>
<MuiStepper activeStep={activeStep} alternativeLabel variant="elevation">