Closed wottpal closed 1 month ago
It's useful to get an (automatic) index value for each step, e.g. when showing something like "Step {index} of {total}".
index
Currently I'm using a small helper function like:
function getStepIndex(step: (typeof steps)[number]) { return steps.findIndex((_step) => step.id === _step.id) as number }
In v3.1 an index is added to the current step. I can definitely add this
Oh sweet, yes that works perfectly fine. Didn't see this release yet.
It's useful to get an (automatic)
index
value for each step, e.g. when showing something like "Step {index} of {total}".Currently I'm using a small helper function like: