reloadAll vs clearPreviousHistory

What is the exact difference beteen those options for router.navigate? I find that most of the time I can use both to achieve the same result, but I would like to better understand the difference.

Во-первых, описание не совсем верное - clearPreviousHistory удаляет и сами страницы и историю.

Во-вторых reloadAll используется для masterDetail - для перезагрузки всех страниц.

В-третьих - остальное знает автор:)

1 Like

reloadAll options “reloads” the current page with new one (without animation, just replace it) and removes everything else from DOM and history
clearPreviousHisory - first navigates to new page (with animation), and then removes all previous pages from DOM and history

So result is basically the same, just a way to get it a bit different

1 Like