0

I would like to ask you how to solve problem with angular stepper and browser history's buttons.

When user making something which includes process steps its easy to controll steps with application button for prev and next step but when we make process step without changing route we are not able to use browser history's buttons, because route is not changing.

If we want to change funcionality to use different route for every single step maybe with only url step parameter. How we can prevent that user, which is on step1, cant rewrite url param to step2. Specialy if step1 has logic which send user to step3 without step2.

We tryed to use canDeactivate and on browser back we just do prevstep but its not so good solution and dont work as we expect.

Is there any solutin with single page app with Angular 10?

thanks.

  • Welcome to Stack Overflow! Very rarely do people just simply write code for you. We'd like to see you put some effort into your code and display it in the question. Check out [here](https://stackoverflow.com/help/how-to-ask) if you want to see how. – PerplexingParadox May 03 '21 at 12:59
  • Since you don’t have any code example all I can really say is use a mixture of canActivate and stepper session state to maintain the stepper process data. – Ben L May 04 '21 at 02:53

0 Answers0