jumpToStep method

void jumpToStep(
  1. int step
)

Jumps directly to the specified step.

Parameters:

  • step (int): zero-based step index to navigate to

Example:

// Jump to final step
controller.jumpToStep(steps.length - 1);

Implementation

void jumpToStep(int step) {
  value = StepperValue(
    stepStates: value.stepStates,
    currentStep: step,
  );
}