americanexpress / react-albus

✨ React component library for building declarative multi-step flows.
Apache License 2.0
1.1k stars 89 forks source link

Feature: Add new set method to navigate directly to a particular step #83

Closed leibowitz closed 3 years ago

leibowitz commented 4 years ago

Add a new set(id) method, to navigate straight to a specific step (using the id).

This can be useful when doing non-linear wizard, where a user can do partial form submission.

leibowitz commented 3 years ago

I've just noticed this line is actually changing the behaviour of replace https://github.com/americanexpress/react-albus/pull/83/commits/8eb6bbd6aabb4002e4865d7e715b3a7fe9c11770#diff-dcbff46be2d315a607e3dca3aa6c6cc3a5033032774843f38f199684b8258758R96

That was probably an oversight on my part.

leibowitz commented 3 years ago

Just in case, I've sent another PR to restore the original behaviour https://github.com/americanexpress/react-albus/pull/85